Systems and methods for processing analyte sensor data

ABSTRACT

Systems and methods for applying time-dependent algorithmic compensation functions to data output from a continuous analyte sensor. Some embodiments determine a time since sensor implantation and/or whether a newly initialized sensor has been used previously, for example, by initializing a sensor, acquiring sensor data, using the sensor, to measure an analyte level in the host&#39;s body over a first interval based on a first elapsed time since the sensor was implanted, determining whether the sensor has been previously used in a previous sensor session or the sensor is a new sensor, and upon determining the sensor is a new sensor, adjusting the acquired sensor data to compensate for sensor drift of the new sensor by applying a first set of time-dependent algorithmic functions to the sensor data associated with the first interval.

INCORPORATION BY REFERENCE TO RELATED APPLICATIONS

Any and all priority claims identified in the Application Data Sheet, orany correction thereto, are hereby incorporated by reference under 37CFR 1.57. This application is a continuation of U.S. application Ser.No. 13/796,185 filed Mar. 12, 2013, which claims the benefit of U.S.Provisional Application No. 61/612,129, filed Mar. 16, 2012. Each of theaforementioned applications is incorporated by reference herein in itsentirety, and each is hereby expressly made a part of thisspecification.

FIELD OF THE INVENTION

The present embodiments relate to systems and methods for processinganalyte sensor data from a continuous analyte sensor, including adaptivealgorithms.

BACKGROUND OF THE INVENTION

Diabetes mellitus is a disorder in which the pancreas cannot createsufficient insulin (Type I or insulin dependent) and/or in which insulinis not effective (Type 2 or non-insulin dependent). In the diabeticstate, the victim suffers from high blood sugar, which can cause anarray of physiological derangements associated with the deterioration ofsmall blood vessels, for example, kidney failure, skin ulcers, orbleeding into the vitreous of the eye. A hypoglycemic reaction (lowblood sugar) can be induced by an inadvertent overdose of insulin, orafter a normal dose of insulin or glucose-lowering agent accompanied byextraordinary exercise or insufficient food intake.

Conventionally, a person with diabetes carries a self-monitoring bloodglucose (SMBG) monitor, which typically requires uncomfortable fingerpricks to obtain blood samples for measurement. Due to the lack ofcomfort and convenience associated with finger pricks, a person withdiabetes normally only measures his or her glucose levels two to fourtimes per day. Unfortunately, time intervals between measurements can bespread far enough apart that the person with diabetes finds out too lateof a hyperglycemic or hypoglycemic condition, sometimes incurringdangerous side effects. It is not only unlikely that a person withdiabetes will take a timely SMBG value, it is also likely that he or shewill not know if his or her blood glucose value is going up (higher) ordown (lower) based on conventional methods. Diabetics thus may beinhibited from making educated insulin therapy decisions.

Another device that some diabetics use to monitor their blood glucose isa continuous analyte sensor. A continuous analyte sensor typicallyincludes a sensor that is placed subcutaneously, transdermally (e.g.,transcutaneously), or intravascularly. The sensor measures theconcentration of a given analyte within the body, and generates a rawsignal that is transmitted to electronics associated with the sensor.The raw signal is converted into an output value that is displayed on adisplay. The output value that results from the conversion of the rawsignal is typically expressed in a form that provides the user withmeaningful information, such as blood glucose expressed in mg/dL.

After the sensor is implanted, it is calibrated, after which it providessubstantially continuous sensor data to the sensor electronics. Thesensor electronics convert the sensor data so that estimated analytevalues can be continuously provided to the user. As used herein, theterms “substantially continuous,” “continuously,” etc., may refer to adata stream of individual measurements taken at time-spaced intervals,which may range from fractions of a second up to, for example, 1, 2, or5 minutes or more. As the sensor electronics continue to receive sensordata, the sensor may be occasionally recalibrated to account forpossible changes in sensor sensitivity and/or baseline (drift). Sensorsensitivity may refer to an amount of electrical current produced in thesensor by a predetermined amount of the measured analyte. Sensorbaseline may refer to a signal output by the sensor when no analyte isdetected. Over time, sensitivity and baseline change due to a variety offactors. Example factors include cellular attack or migration of cellsto the sensor, which can affect the ability of the analyte to reach thesensor. Preferably, drift is taken into consideration when applying aconversion function to the raw data, so that accurate readings can beprovided to the user.

SUMMARY OF THE INVENTION

The various embodiments of the present systems and methods forprocessing analyte sensor data have several features, no single one ofwhich is solely responsible for their desirable attributes. Withoutlimiting the scope of the present embodiments as expressed by the claimsthat follow, their more prominent features now will be discussedbriefly. After considering this discussion, and particularly afterreading the section entitled “Detailed Description,” one will understandhow the features of the present embodiments provide the advantagesdescribed herein.

One aspect of the present embodiments includes the realization that,with some sensors, typically the greatest rate of drift occurs duringthe first day to three days after implantation of a new sensor, afterwhich the rate of change of drift typically levels off. Thus, the needto recalibrate the sensor is greatest during the first day to three daysafter implantation. However, lack of host compliance can lead todifficulty in properly recalibrating the sensor. For example, currentgovernment regulations require that today's sensors be replaced atmandated intervals. However, the more sensors a host uses, the moresensors he or she must purchase. Thus, there is an economic incentivefor hosts to reuse old sensors rather than always implanting a newsensor at the end of each life cycle. If it is assumed that each sensoris new when it is initialized, improper assumptions aboutcalibration/recalibration may be applied to the sensor, and the host mayreceive an artificially inflated or deflated reading of his or her bloodglucose, with possible attendant side effects. It would thus bebeneficial if it could be determined whether a sensor is new or has beenreused, so that appropriate drift compensation, for example, could beapplied to the signal output by the sensor.

In a first aspect, a method for processing sensor data output by acontinuous analyte sensor implanted within a body is provided, themethod comprising: measuring a change in sensitivity or baseline of thesensor over a time interval; determining a drift compensation functionto be applied to a plurality of time-spaced data points output by thesensor; and applying the drift compensation function continuously to thedata points.

In an embodiment of the first aspect, measuring the change insensitivity or baseline of the sensor comprises comparing a firstmeasured sensitivity or baseline of the sensor to a second measuredsensitivity or baseline of the sensor, wherein the first and secondmeasured sensitivities or baselines of the sensor are taken at abeginning and an end, respectively, of the time interval.

The drift compensation function may be determined based on rate ofchange in sensitivity or baseline of the sensor as determined from themeasuring step.

In an embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, measuringthe change in sensitivity or baseline of the sensor comprises comparinga measured sensitivity or baseline of the sensor to a predeterminedsensitivity or baseline of the sensor. The predetermined sensitivity orbaseline of the sensor may be based on an earlier measurement thereofand may be retrieved from memory.

The change in sensitivity or baseline may be obtained from referenceanalyte data, which is not taken from the sensor analyte measurements.That is, the change in sensitivity or baseline is preferably taken froma separate test from the analyte measurements being made by the analytesensor.

In an embodiment of the first aspect, a value of the predeterminedsensitivity or baseline of the sensor is assigned according to knowncharacteristics of the body in which the sensor is implanted.

In an embodiment of the first aspect, the characteristics include atleast one of age, body type, gender, diabetes type, diabetes duration,concomitant diseases and/or sensor location.

In an embodiment of the first aspect, the predetermined sensitivity orbaseline of the sensor is based on a measured impedance of the sensor.

In an embodiment of the first aspect, the impedance of the sensor ismeasured in vitro.

In an embodiment of the first aspect, the impedance of the sensor ismeasured in vivo.

In an embodiment of the first aspect, determining a drift compensationfunction to be applied is based, at least in part, on the predeterminedsensitivity or baseline. The drift compensation function may be based onthe measured change in sensitivity or baseline over time.

In an embodiment of the first aspect, a value of the predeterminedsensitivity or baseline is encoded on electronics associated with thesensor.

An embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, furthercomprises comparing the measured change in sensitivity or baseline ofthe sensor to a priori knowledge regarding the change in sensitivity orbaseline of the sensor over the time interval.

An embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, furthercomprises based on the measured change in sensitivity or baseline of thesensor, determining whether the sensor has been previously used.

In an embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, measuringthe change in sensitivity of the sensor over the time interval comprisescalculating a drift rate of the sensor over the time interval. The driftcompensation function may be determined based on the drift rate.

In an embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, measuringthe drift rate of the sensor comprises comparing measured analyte valuesto substantially time-corresponding reference analyte values over thetime interval.

An embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, furthercomprises calculating an expected drift rate of the sensor based on aweighted average of a current measured drift rate and at least onepreviously measured drift rate.

In an embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, measuringthe change in sensitivity or baseline of the sensor occurs only afterthe sensor has been implanted within the body for at least a minimumduration.

An embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, furthercomprises measuring a temperature of the body.

An embodiment of the first aspect further comprises using the measuredtemperature to adjust the measured change in sensitivity or baseline ofthe sensor.

An embodiment of the first aspect further comprises using the measuredtemperature as an input when determining the drift compensation functionto be applied.

In an embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, measuringthe change in sensitivity or baseline of the sensor comprises measuringa change in impedance of the sensor.

An embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, furthercomprises prompting a user for a reference analyte value when themeasured change in sensitivity or baseline of the sensor exceeds acriterion.

An embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, furthercomprises storing the change in sensitivity or baseline of the sensorfor later use.

In an embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, the applieddrift compensation function is a stepwise function. A scaling factorapplied to the sensor data for drift compensation may be calculated ateach step. The calculation of the scaling factor may be based on data orparameters from calibration operations. In particular, the calculationmay be based on a drift rate in parameters obtained from time separatedcalibration operations, the parameters for defining a relationshipbetween raw sensor data and reference analyte data.

In an embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, the applieddrift compensation function is a mathematical inverse of a mathematicalequation that describes the change in sensitivity or baseline of thesensor over the time interval.

In an embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, a prioriknowledge of sensor sensitivity and/or baseline drift is used to modeland apply drift compensation within a Kalman filter framework.

An embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, furthercomprises applying boundaries to the drift compensation function.

In an embodiment of the first aspect, the boundaries are based on apriori knowledge.

In an embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, measuringthe change in sensitivity or baseline of the sensor comprises taking twodistinct measurements according to two distinct techniques.

An embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, furthercomprises measuring an absolute sensitivity or baseline of the sensor ata time t, and wherein determining the drift compensation function to beapplied to the plurality of time-spaced data points output by the sensoris based on the measured absolute sensitivity or baseline.

An embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, furthercomprises ceasing applying the drift compensation function continuouslyto the data points when the measured change in sensitivity or baselineof the sensor is below a threshold value.

An embodiment of the first aspect, which is generally applicable,particularly with any other embodiment of the first aspect, furthercomprises ceasing applying the drift compensation function continuouslyto the data points after a predetermined amount of time has elapsed.

In an embodiment of the first aspect, the step of measuring a change insensitivity or baseline of the sensor occurs over a first time interval,the step of determining a drift compensation function is based on themeasured change in sensitivity or baseline of the sensor over the firsttime interval, and the step of applying the drift compensation functionis to continuously adjust the sensor data output to compensate forchanges in sensitivity or baseline of the sensor over a second timeinterval.

In a second aspect, a system for processing data is provided, the systemcomprising: a continuous analyte sensor configured to be implantedwithin a body; and sensor electronics configured to receive and processsensor data output by the sensor, the sensor electronics including aprocessor configured to measure a change in sensitivity or baseline ofthe sensor over an interval of time; determine a drift compensationfunction to be applied to a plurality of time-spaced data points outputby the sensor over a next interval of time; and apply the driftcompensation function continuously to the data points over the nextinterval of time.

In an embodiment of the second aspect, measuring the change insensitivity or baseline of the sensor comprises comparing a firstmeasured sensitivity or baseline of the sensor to a second measuredsensitivity or baseline of the sensor, wherein the first and secondmeasured sensitivities or baselines of the sensor are taken at abeginning and an end, respectively, of the time interval.

In an embodiment of the second aspect, the processor is furtherconfigured to compare a measured sensitivity or baseline of the sensorto a predetermined sensitivity or baseline of the sensor.

In an embodiment of the second aspect, a value of the predeterminedsensitivity or baseline of the sensor is assigned according to knowncharacteristics of the body in which the sensor is implanted.

In an embodiment of the second aspect, the characteristics include atleast one of age, body type, gender, diabetes type, diabetes duration,concomitant diseases and/or sensor location.

In an embodiment of the second aspect, the predetermined sensitivity orbaseline of the sensor is based on a measured impedance of the sensor.

In an embodiment of the second aspect, the impedance of the sensor ismeasured in vitro.

In an embodiment of the second aspect, the impedance of the sensor ismeasured in vivo.

In an embodiment of the second aspect, determining a drift compensationfunction to be applied is based, at least in part, on the predeterminedsensitivity or baseline.

In an embodiment of the second aspect, a value of the predeterminedsensitivity or baseline is encoded on the sensor electronics.

In an embodiment of the second aspect, the processor is furtherconfigured to compare the measured change in sensitivity or baseline ofthe sensor to a priori knowledge regarding the change in sensitivity orbaseline of the sensor over the time interval.

In an embodiment of the second aspect, measuring the change insensitivity of the sensor over the time interval comprises calculating adrift rate of the sensor over the time interval.

In an embodiment of the second aspect, measuring the drift rate of thesensor comprises comparing measured analyte values to substantiallytime-corresponding reference analyte values over the time interval.

In an embodiment of the second aspect, the processor is furtherconfigured to calculate an expected drift rate of the sensor based on aweighted average of a current measured drift rate and at least onepreviously measured drift rate.

In an embodiment of the second aspect, measuring the change insensitivity or baseline of the sensor occurs only after the sensor hasbeen implanted within the body for at least a minimum duration.

An embodiment of the second aspect further comprises a temperaturesensor configured to measure a temperature of the body.

In an embodiment of the second aspect, the processor is furtherconfigured to use the measured temperature to adjust the measured changein sensitivity or baseline of the sensor.

In an embodiment of the second aspect, the processor is furtherconfigured to use the measured temperature as an input when determiningthe drift compensation function to be applied.

In an embodiment of the second aspect, measuring the change insensitivity or baseline of the sensor comprises measuring a change inimpedance of the sensor.

In an embodiment of the second aspect, the processor is furtherconfigured to prompt a user for a reference analyte value when themeasured change in sensitivity or baseline of the sensor exceeds acriteria.

In an embodiment of the second aspect, the processor is furtherconfigured to store the change in sensitivity or baseline of the sensorfor later use.

In an embodiment of the second aspect, the applied drift compensationfunction is a stepwise function.

In an embodiment of the second aspect, the applied drift compensationfunction is a mathematical inverse of a mathematical equation thatdescribes the change in sensitivity or baseline of the sensor over thetime interval.

In an embodiment of the second aspect, a priori knowledge of sensorsensitivity and/or baseline drift is used to model and apply driftcompensation within a Kalman filter framework.

In an embodiment of the second aspect, the processor is furtherconfigured to apply boundaries to the drift compensation function.

In an embodiment of the second aspect, the boundaries are based on apriori knowledge.

In an embodiment of the second aspect, measuring the change insensitivity or baseline of the sensor comprises taking two distinctmeasurements according to two distinct techniques.

In an embodiment of the second aspect, the processor is furtherconfigured to measure an absolute sensitivity or baseline of the sensorat a time t, and wherein determining the drift compensation function tobe applied to the plurality of time-spaced data points output by thesensor is based on the measured absolute sensitivity or baseline.

In an embodiment of the second aspect, the processor is furtherconfigured to cease applying the drift compensation functioncontinuously to the data points when the measured change in sensitivityor baseline of the sensor is below a threshold value.

In an embodiment of the second aspect, the processor is furtherconfigured to cease applying the drift compensation functioncontinuously to the data points after a predetermined amount of time haselapsed.

In an embodiment of the second aspect, the processor is configured todetermine a drift compensation function based on the measured change insensitivity or baseline of the sensor over the interval of time, and toapply the drift compensation function continuously to the data pointsover the next interval of time to continuously adjust the sensor dataoutput to compensate for changes in sensitivity or baseline of thesensor over a second time interval.

In a third aspect, a method for processing sensor data of a continuousanalyte sensor implanted within a body is provided, the methodcomprising: initializing the sensor; applying a first (set of)time-dependent algorithmic function(s) to data associated with thesensor during a first interval based on a first elapsed time since thesensor was implanted; and applying a second (set of) time-dependentalgorithmic function(s) to the data associated with the sensor during asecond interval after the first interval based on a second elapsed timesince the sensor was implanted.

In an embodiment of the third aspect, which is generally applicable,particularly with any other embodiment of the third aspect, initializingthe sensor comprises engaging electronics associated with the sensorwith a housing.

In an embodiment of the third aspect, which is generally applicable,particularly with any other embodiment of the third aspect, engagementof the electronics with the receiving unit is detected andinitialization commences automatically upon detection of the engagement.

In an embodiment of the third aspect, which is generally applicable,particularly with any other embodiment of the third aspect, initializingthe sensor comprises prompting a user via a user interface associatedwith the sensor.

In an embodiment of the third aspect, which is generally applicable,particularly with any other embodiment of the third aspect, the usercommences the initialization by entering a command via a menu on theuser interface.

An embodiment of the third aspect, which is generally applicable,particularly with any other embodiment of the third aspect, furthercomprises determining whether the sensor has been previously used.

In an embodiment of the third aspect, determining whether the sensor hasbeen previously used comprises: determining a time, delta T, since theprior sensor session ended and the current sensor session wasinitialized; if T is less than a threshold value, determining that thesensor has not been previously used; and if T is greater than thethreshold value, determining that the sensor has been previously used.

In an embodiment of the third aspect, determining whether the sensor hasbeen previously used comprises prompting a user for input.

In an embodiment of the third aspect, the input is a unique numberassociated with the sensor.

In an embodiment of the third aspect, determining whether the sensor hasbeen previously used comprises reading a radio frequency identifierassociated with the sensor.

In an embodiment of the third aspect, determining whether the sensor hasbeen previously used comprises comparing a conversion function of thesensor with a conversion function of a previously removed sensor.

In an embodiment of the third aspect, determining whether the sensor hasbeen previously used comprises: measuring a change in impedance of thesensor over a time, T; if the change in the impedance is less than athreshold value, determining that the sensor has been previously used;and if the change in the impedance is greater than the threshold value,determining that the sensor has not been previously used.

In an embodiment of the third aspect, determining whether the sensor hasbeen previously used comprises reading a raw signal of the sensor.

In an embodiment of the third aspect, determining whether the sensor hasbeen previously used comprises comparing a sensitivity and/or baselineof the sensor with a sensitivity and/or baseline of a previously removedsensor.

In an embodiment of the third aspect, determining whether the sensor hasbeen previously used comprises comparing a trend in a signal from thesensor with a trend in a signal from a previously removed sensor.

In an embodiment of the third aspect, determining whether the sensor hasbeen previously used comprises performing two or more independent testsand then determining a probability that the sensor has been previouslyused based upon results of the tests.

In an embodiment of the third aspect, a result of a first one of the twoor more independent tests that is likely to be more reliable is weightedmore heavily than a result of a second one of the two or moreindependent tests that is likely to be less reliable.

In an embodiment of the third aspect, the above embodiments fordetermining whether the sensor has been previously used may be combinedin any way. That is, any two, three or more of the embodiments fordetermining whether the sensor has been used may be combined.

In an embodiment of the third aspect, which is generally applicable,particularly with any other embodiment of the third aspect, applying thefirst set of time-dependent algorithmic functions comprises applyingdrift compensation to the data associated with the sensor.

In an embodiment of the third aspect, which is generally applicable,particularly with any other embodiment of the third aspect, the firstand second set of time-dependent algorithmic functions comprise firstand second boundaries of acceptability.

In an embodiment of the third aspect, the first boundary comprises afirst sensitivity value and the second boundary comprises a secondsensitivity value.

In an embodiment of the third aspect, the first boundary comprises afirst baseline value and the second boundary comprises a second baselinevalue.

In an embodiment of the third aspect, the first boundary delineates afirst acceptable deviation of one or more match data pairs and thesecond boundary delineates a second acceptable deviation of one or morematched data pairs.

In an embodiment of the third aspect, the first boundary comprises afirst drift rate of the sensitivity over a time period and the secondboundary comprises a second drift rate of the sensitivity over time.

In an embodiment of the third aspect, the first boundary comprises afirst drift rate of the baseline over a time period and the secondboundary comprises second drift rate of the baseline over time.

In an embodiment of the third aspect, the first boundary delineatesacceptable slopes and baselines of a conversion function and the secondboundary delineates acceptable slopes and baselines of the conversionfunction.

In an embodiment of the third aspect, the second boundary is higher thanthe first boundary

In an embodiment of the third aspect, the second boundary is lower thanthe first boundary

In an embodiment of the third aspect, the second boundary comprises arange that is more narrow than the first boundary

In an embodiment of the third aspect, the second boundary comprises arange that is wider than the first boundary.

In an embodiment of the third aspect, which is generally applicable,particularly with any other embodiment of the third aspect, the firstand second set of time-dependent algorithmic functions comprise firstand second parameters associated with the conversion function.

In an embodiment of the third aspect, the first and second parametersassociated with the conversion function define a number of matched datapairs or a window of time over which matched data pairs may be includedin a calibration set, wherein the conversion function is based on thecalibration set.

In an embodiment of the third aspect, the conversion function is basedon predetermined baseline information, and wherein the first and secondparameters comprise first and second baseline information.

In an embodiment of the third aspect, the wherein the first and secondset of time-dependent algorithmic functions comprise first and seconddrift compensation functions.

In an embodiment, the method comprises determining the second driftcompensation function based on more recent sensor drift data than thatused to determine the first drift compensation function. The first driftcompensation function may be determined based on data or parameters usedin first and second time separated calibration operations fordetermining respective conversion functions for converting raw sensordata to analyte data. The second drift compensation function may bedetermined based on data or parameters used a third calibrationoperation subsequent to the second calibration operation and used in atleast one of the first and second calibration operations. In particular,the first and second drift compensation functions are determined basedon sensor drift rate data obtained from preceding calibrationoperations. The second drift compensation function is determined basedon sensor drift rate data from more recent calibration operations thanthose used for determining the first drift compensation function.

In an embodiment of the third aspect, the first and second driftcompensation functions differ in the amount of drift compensation thatthey apply.

In a fourth aspect, a system for processing sensor data of a continuousanalyte sensor implanted within a body is provided, the systemcomprising: a continuous analyte sensor configured to be implantedwithin a body; and sensor electronics configured to receive and processsensor data output by the sensor, the sensor electronics including aprocessor configured to initialize the sensor; apply a first (set of)time-dependent algorithmic function(s) to data associated with thesensor during a first interval based on a first elapsed time since thesensor was implanted; and apply a second (set of) time-dependentalgorithmic function(s) to the data associated with the sensor during asecond interval after the first interval based on a second elapsed timesince the sensor was implanted.

In an embodiment of the fourth aspect, initialization of the sensorcommences automatically when the sensor electronics engages a housing.

In an embodiment of the fourth aspect, initialization of the sensorcommences after a user enters a command on a user interface associatedwith the sensor.

In an embodiment of the fourth aspect, the processor is furtherconfigured to determine whether the sensor has been previously used.

In an embodiment of the fourth aspect, determining whether the sensorhas been previously used comprises: determining a time, delta T, sincethe prior sensor session ended and the current sensor session wasinitialized; if T is less than a threshold value, determining that thesensor has not been previously used; and if T is greater than thethreshold value, determining that the sensor has been previously used.

In an embodiment of the fourth aspect, determining whether the sensorhas been previously used comprises prompting a user for input.

In an embodiment of the fourth aspect, the input is a unique numberassociated with the sensor.

In an embodiment of the fourth aspect, determining whether the sensorhas been previously used comprises reading a radio frequency identifierassociated with the sensor.

In an embodiment of the fourth aspect, determining whether the sensorhas been previously used comprises comparing a conversion function ofthe sensor with a conversion function of a previously removed sensor.

In an embodiment of the fourth aspect, determining whether the sensorhas been previously used comprises: measuring a change in impedance ofthe sensor over a time, T; if the change in the impedance is less than athreshold value, determining that the sensor has been previously used;and if the change in the impedance is greater than the threshold value,determining that the sensor has not been previously used.

In an embodiment of the fourth aspect, determining whether the sensorhas been previously used comprises reading a raw signal of the sensor.

In an embodiment of the fourth aspect, determining whether the sensorhas been previously used comprises comparing a sensitivity and/orbaseline of the sensor with a sensitivity and/or baseline of apreviously removed sensor.

In an embodiment of the fourth aspect, determining whether the sensorhas been previously used comprises comparing a trend in a signal fromthe sensor with a trend in a signal from a previously removed sensor.

In an embodiment of the fourth aspect, determining whether the sensorhas been previously used comprises performing two or more independenttests and then determining a probability that the sensor has beenpreviously used based upon results of the tests.

In an embodiment of the fourth aspect, a result of a first one of thetwo or more independent tests that is likely to be more reliable isweighted more heavily than a result of a second one of the two or moreindependent tests that is likely to be less reliable.

In an embodiment of the fourth aspect, applying the first set oftime-dependent algorithmic functions comprises applying driftcompensation to the data associated with the sensor.

In an embodiment of the fourth aspect, the first and second set oftime-dependent algorithmic functions comprise first and secondboundaries of acceptability.

In an embodiment of the fourth aspect, the first boundary comprises afirst sensitivity value and the second boundary comprises a secondsensitivity value.

In an embodiment of the fourth aspect, the first boundary comprises afirst baseline value and the second boundary comprises a second baselinevalue.

In an embodiment of the fourth aspect, the first boundary delineates afirst acceptable deviation of one or more match data pairs and thesecond boundary delineates a second acceptable deviation of one or morematched data pairs.

In an embodiment of the fourth aspect, the first boundary comprises afirst drift rate of the sensitivity over a time period and the secondboundary comprises second drift rate of the sensitivity over time.

In an embodiment of the fourth aspect, the first boundary comprises afirst drift rate of the baseline over a time period and the secondboundary comprises second drift rate of the baseline over time.

In an embodiment of the fourth aspect, the first boundary delineatesacceptable slopes and baselines of a conversion function and the secondboundary delineates acceptable slopes and baselines of the conversionfunction.

In an embodiment of the fourth aspect, the second boundary is higherthan the first boundary

In an embodiment of the fourth aspect, the second boundary is lower thanthe first boundary

In an embodiment of the fourth aspect, the second boundary comprises arange that is more narrow than the first boundary

In an embodiment of the fourth aspect, the second boundary comprises arange that is wider than the first boundary.

In an embodiment of the fourth aspect, the first and second set oftime-dependent algorithmic functions comprise first and secondparameters associated with the conversion function.

In an embodiment of the fourth aspect, the first and second parametersassociated with the conversion function define a number of matched datapairs or a window of time over which matched data pairs may be includedin a calibration set, wherein the conversion function is based on thecalibration set.

In an embodiment of the fourth aspect, the conversion function is basedon predetermined baseline information, and wherein the first and secondparameters comprises first and second baseline information.

In an embodiment of the fourth aspect, the first and second set oftime-dependent algorithmic functions comprise first and second driftcompensation functions.

In an embodiment of the fourth aspect, the first and second driftcompensation functions differ in the amount of drift compensation thatthey apply.

The above first and second aspects and the associated embodiments arecombinable with the above third and fourth aspects and associatedembodiments. In one form, the step of measuring the change insensitivity of the first and second aspects and associated embodimentsmay be used to determine the first and/or second time dependentalgorithms of the third and fourth aspects and associated embodiments.Additionally or alternatively, the step of determining a driftcompensation function of the first and second aspects and associatedembodiments can be used to determine the first and/or second timedependent algorithms of the third and fourth aspects. Additionally oralternatively, the initializing step of the third and fourth aspects andassociated embodiments is applicable to the third and fourth aspects andassociated embodiments.

In a fifth aspect, there is provided a method comprising converting rawsensor data from an analyte sensor implanted within a body to analytesensor data using a conversion function; and applying a driftcompensation function to the raw sensor data or the analyte sensor datato compensate for sensor drift in a responsiveness of the analyte sensorto an analyte being sensed.

The feature of converting raw sensor data from an analyte sensor toanalyte data using a conversion function is applicable to all aspectsand embodiments identified herein. Further, the feature concerningmeasuring the change in sensitivity in the above first and secondaspects (and associated embodiments) may be made optional. Conversely,the measuring feature of the first and second aspects (and theassociated embodiments) is applicable to the other aspects including thefifth aspect. The initializing step of the third and fourths aspect (andthe associated embodiments) is applicable to the fifth aspect. Thediffering features of the above first to fourth aspects and theassociated embodiments are combinable with the fifth aspect.

In a generally applicable embodiment (i.e. independently combinable withany of the aspects or embodiments identified herein), the driftcompensation function is applied to the sensor data to vary the sensordata over a time interval over which the conversion function does notvary.

In a generally applicable embodiment, the drift compensation function isapplied to vary sensor data over time increments between successivecalibrations of the conversion function. Thus, the sensor data is variedat small time steps during a relatively long time interval betweencalibration events when a constant conversion function is used.

In a generally applicable embodiment, the conversion function is setbased on a relationship between reference analyte data and raw sensordata. Analyte sensor drift causes this relationship to vary over time,which variance is compensated for by the drift compensation function.

In a generally applicable embodiment, the drift compensation function isderived from a change in a relationship between raw sensor data andreference analyte data over a preceding time interval. The change in arelationship may be in the form of a rate of change. The referenceanalyte data is determined otherwise than by way of the conversionfunction. For example, a separate test for the analyte could beperformed (e.g. blood test).

In a generally applicable embodiment, time separated conversionfunctions are determined in respective calibration operations, theconversion functions respectively defining a relationship between rawsensor data and reference analyte data, wherein the drift compensationfunction is derived from a change in (e.g. one or more parameters of)conversion functions over time.

In a generally applicable embodiment, the drift compensation function isdetermined based on data or parameters from at least two calibrationevents for determining respective conversion functions.

In a generally applicable embodiment, the drift compensation function isdetermined at a first point in time and redetermined at a later point intime based on more recent data. In particular, the drift compensationfunction is determined at each of time spaced calibration events and thedrift compensation function is determined based on data or parameters atleast from the more recent calibration process and preferably also fromat least the directly preceding calibration process. In a generallyapplicable embodiment, the drift compensation function defines a scalingfactor or function applied to the sensor data such that the magnitude ofthe sensor data varies with time.

In a generally applicable embodiment, a frequency of conversion functioncalibrations is varied depending upon a drift rate of the sensor asderivable from the drift compensation function. This is also anindependently applicable aspect in that a method could be provided inwhich a conversion function is used to convert raw sensor data from ananalyte sensor implanted within a body to analyte data, wherein theconversion function is calibrated at time intervals, wherein a frequencyof calibrations is set depending upon a determined drift rate of theanalyte sensor with regard to its responsiveness to the analyte beingsensed. A more recent calibration is based on more recent dataconcerning a relationship between raw sensor data and reference analytedata.

In a generally applicable embodiment, a frequency of conversion functioncalibration requests is varied depending upon a drift rate of the sensoras derivable from the drift compensation function. This is also anindependently applicable aspect in that a method could be provided inwhich a conversion function is used to convert raw sensor data from ananalyte sensor implanted within a body to analyte data, wherein theconversion function is calibrated at time intervals, wherein a frequencyof calibration requests is set depending upon a determined drift rate ofthe analyte sensor with regard to its responsiveness to the analytebeing sensed. A more recent calibration is based on more recent dataconcerning a relationship between raw sensor data and reference analytedata. A calibration request may be provided in the form or a prompt forreference analyte data. The request may be a request to a user.

In a generally applicable embodiment, a frequency of conversion functioncalibrations or requests therefor increases as a drift rate increases.

In a generally applicable embodiment, drift compensation ceases to beapplied after a set amount of time or after a determination that sensordrift rate is sufficiently low.

In further aspects and embodiments, the above method features areformulated in terms of a system having the analyte sensor and controlmeans configured to carry out the method features.

BRIEF DESCRIPTION OF THE DRAWINGS

The various embodiments of the present systems and methods forprocessing analyte sensor data now will be discussed in detail with anemphasis on highlighting the advantageous features. These embodimentsdepict the novel and non-obvious systems and methods shown in theaccompanying drawings, which are for illustrative purposes only. Thesedrawings include the following figures, in which like numerals indicatelike parts:

FIG. 1 is a schematic view of a continuous analyte sensor systemattached to a host and communicating with a plurality of exampledevices;

FIG. 2 is a graph illustrating a relationship between analyteconcentration and a signal from a continuous analyte sensor at time=t₀;

FIG. 3 is a graph illustrating a relationship between analyteconcentration and a signal from the continuous analyte sensor attime=t_(n);

FIG. 4 is a graph illustrating sensitivity of a continuous analytesensor over time;

FIG. 5 is a graph illustrating a drift compensation function for thecurve shown in FIG. 4;

FIG. 6 is a graph superimposing the curves shown in FIGS. 4 and 5;

FIG. 7 is a flowchart illustrating a process for applying time-dependentalgorithmic functions to sensor data, in accordance with the presentembodiments;

FIG. 7A is a flowchart illustrating a process for applyingtime-dependent algorithmic functions to sensor data, in accordance withthe present embodiments;

FIG. 8 is a graph illustrating a signal of a continuous analyte sensorover time, and a signal of the same continuous analyte sensor over timeafter it is reinitialized;

FIG. 9 is a graph illustrating a signal of a first continuous analytesensor over time, and a signal of a second continuous analyte sensorafter the first continuous analyte sensor is removed and the secondcontinuous analyte sensor is implanted;

FIG. 10 is a flowchart illustrating a process for determining animpedance of a sensor, in accordance with the present embodiments;

FIG. 11 is a flowchart illustrating a process for determining animpedance or plurality of impedances of a sensor being studied byapplying one or more stimulus signals and converting the response signalor signals to a frequency domain, in accordance with the presentembodiments;

FIG. 12 is a flowchart illustrating a process for determining animpedance of a sensor being studied, in accordance with the presentembodiments;

FIG. 13A is a graph of an input voltage applied to an analyte sensorover time, in accordance with the present embodiments;

FIG. 13B is a graph of a current response of the analyte sensor to theinput voltage of FIG. 13A;

FIG. 14 is a graph that illustrates one example of using priorinformation for slope and baseline;

FIG. 15 is a flowchart illustrating a process for applying driftcompensation to sensor data, in accordance with the present embodiments;

FIG. 16 is a flowchart illustrating a process for compensating sensordata for changes in sensitivity, in accordance with the presentembodiments;

FIG. 17 is a flowchart illustrating a process for determining apredicted sensitivity profile using one or more sensor membraneimpedance values, in accordance with the present embodiments;

FIG. 18 is a flowchart illustrating a process for determining whether ananalyte sensor under test is functioning properly based on a predictedsensitivity profile and one or more impedance measurements, inaccordance with the present embodiments;

FIG. 19 is a flowchart illustrating a process for determining a sensortemperature, in accordance with the present embodiments;

FIG. 20 is a graph illustrating a drift compensation function for asignal from a continuous analyte sensor; and

FIG. 21 is a graph illustrating a linear piece-wise function forapplying the drift compensation function of FIG. 20 to the signal fromthe continuous analyte sensor.

DETAILED DESCRIPTION

The following detailed description describes the present embodimentswith reference to the drawings. In the drawings, reference numbers labelelements of the present embodiments. These reference numbers arereproduced below in connection with the discussion of the correspondingdrawing features.

Sensor System and Applicator

FIG. 1 is a schematic view of a continuous analyte sensor system 100attached to a host and communicating with a number of example devices110-113. A transcutaneous analyte sensor system comprising an on-skinsensor assembly 100 is fastened to the skin of a host via a disposablehousing (not shown). The system includes a transcutaneous analyte sensor102 and a transmitter/sensor electronics unit 104 for wirelesslytransmitting analyte information to a receiver. In alternativeembodiments, the sensor may be non-invasive.

During use, a sensing portion of the sensor 102 is under the host'sskin, and a contact portion of the sensor 102 is electrically connectedto the electronics unit 104. The electronics unit 104 engages a housing(not shown), and the sensor extends through the housing. The housing,which maintains the assembly 100 on the skin and provides for electricalconnection of the sensor 102 to sensor electronics provided in theelectronics unit 104, is attached to an adhesive patch fastened to theskin of the host.

The on-skin sensor assembly 100 may be attached to the host with anapplicator (not shown) adapted to provide convenient and secureapplication. Such an applicator may also be used for attaching theelectronics unit 104 to a housing, inserting the sensor 102 through thehost's skin, and/or connecting the sensor 102 to the electronics unit104. Once the electronics unit 104 is engaged with the housing and thesensor 102 has been inserted and is connected to the electronics unit104, the applicator detaches from the sensor assembly.

In general, the continuous analyte sensor system 100 includes any sensorconfiguration that provides an output signal indicative of aconcentration of an analyte. The output signal, which may be in the formof, for example, sensor data, such as a raw data stream, filtered data,smoothed data, and/or otherwise transformed sensor data, is sent to thereceiver, which is described in more detail below. In one embodiment,the analyte sensor system 100 includes a transcutaneous glucose sensor,such as that described in U.S. Patent Application Publication No.2011/0027127, for example, which is incorporated by reference herein inits entirety. In some embodiments, the sensor system 100 includes asubcutaneous glucose sensor, such as that described in U.S. Pat. No.6,579,690 to Bonnecaze et al. or U.S. Pat. No. 6,484,046 to Say et al.,for example. In some embodiments, the sensor system 100 includes acontinuous, refillable, subcutaneous glucose sensor, such as thatdescribed in U.S. Pat. No. 6,512,939 to Colvin et al., for example. Insome embodiments, the sensor system 100 includes a continuousintravascular glucose sensor, such as that described in U.S. Pat. No.6,477,395 to Schulman et al., or U.S. Pat. No. 6,424,847 to Mastrototaroet al., for example. Other signal processing techniques and glucosemonitoring system embodiments suitable for use with the presentembodiments are described in U.S. Patent Application Publication Nos.2005/0203360 and 2009/0192745, both of which are incorporated herein byreference in their entireties.

In some embodiments, the sensor 102 extends through a housing (notshown), which maintains the sensor on the skin and provides forelectrical connection of the sensor to sensor electronics, provided inthe electronics unit 104. In one embodiment, the sensor 102 is formedfrom a wire. For example, the sensor can include an elongated conductivebody, such as a bare elongated conductive core (e.g., a metal wire) oran elongated conductive core coated with one, two, three, four, five, ormore layers of material, each of which may or may not be conductive. Theelongated sensor may be long and thin, yet flexible and strong. Forexample, in some embodiments the smallest dimension of the elongatedconductive body is less than about 0.1 inches, 0.075 inches, 0.05inches, 0.025 inches, 0.01 inches, 0.004 inches, or 0.002 inches.Preferably, a membrane system is deposited over at least a portion ofelectroactive surfaces of the sensor 102 (including a working electrodeand optionally a reference electrode) and provides protection of theexposed electrode surface from the biological environment, diffusionresistance (limitation) of the analyte if needed, a catalyst forenabling an enzymatic reaction, limitation or blocking of interferents,and/or hydrophilicity at the electrochemically reactive surfaces of thesensor interface.

In general, the membrane system includes a plurality of domains, forexample, an electrode domain, an interference domain, an enzyme domain(for example, including glucose oxidase), and a resistance domain, andcan include a high oxygen solubility domain, and/or a bioprotectivedomain, such as is described in more detail in U.S. Patent ApplicationPublication No. 2005/0245799. The membrane system may be deposited onthe exposed electroactive surfaces using known thin film techniques (forexample, spraying, electro-depositing, dipping, or the like). In oneembodiment, one or more domains are deposited by dipping the sensor intoa solution and drawing out the sensor at a speed that provides theappropriate domain thickness. However, the membrane system can bedisposed over (or deposited on) the electroactive surfaces using anyknown method.

In the illustrated embodiment, the electronics unit 104 is releasablyattachable to the sensor 102, which together form the on-skin sensorassembly 100. The electronics unit 104 includes electronic circuitryassociated with measuring and processing the continuous analyte sensordata, and is configured to perform algorithms associated with processingand calibration of the sensor data. For example, the electronics unit104 can provide various aspects of the functionality of a sensorelectronics module as described in U.S. Patent Application PublicationNo. 2009/0240120, which is incorporated herein by reference in itsentirety. The electronics unit 104 may include hardware, firmware,and/or software that enable measurement of levels of the analyte via aglucose sensor, such as the analyte sensor 102. For example, theelectronics unit 104 can include a potentiostat, a power source forproviding power to the sensor 102, other components useful for signalprocessing and data storage, and preferably a telemetry module for one-or two-way data communication between the electronics unit 104 and oneor more receivers, repeaters, and/or display devices, such as thedevices 110-113. Sensor electronics within the electronics unit 104 canbe affixed to a printed circuit board (PCB), or the like, and can take avariety of forms. For example, the electronics can take the form of anintegrated circuit (IC), such as an application-specific integratedcircuit (ASIC), a microcontroller, and/or a processor. The electronicsunit 104 may include sensor electronics that are configured to processsensor information, such as storing data, analyzing data streams,calibrating analyte sensor data, estimating analyte values, comparingestimated analyte values with time corresponding measured analytevalues, analyzing a variation of estimated analyte values, and the like.Examples of systems and methods for processing sensor analyte data aredescribed in more detail herein and in U.S. Pat. Nos. 6,931,327,7,310,544 and in U.S. Patent Application Publication Nos. 2005/0043598,2007/0032706, 2007/0016381, 2008/0033254, 2005/0203360, 2005/0154271,2005/0192557, 2006/0222566, 2007/0203966 and 2007/0208245, each of whichis incorporated herein by reference in its entirety.

One or more repeaters, receivers and/or display devices, such as a keyfob repeater 110, a medical device receiver 111, a smart phone 112, aportable or tablet computer 113, and the like are operatively linked tothe electronics unit 104. The repeaters, receivers and/or displaydevices receive data from the electronics unit 104, which is alsoreferred to as the transmitter and/or sensor electronics body herein. Insome embodiments the repeaters, receivers and/or display devicestransmit data to the electronics unit 104. For example, the sensor datacan be transmitted from the sensor electronics unit 104 to one or moreof the key fob repeater 110, the medical device receiver 111, the smartphone 112, the portable or tablet computer 113, and the like. In oneembodiment, a display device includes an input module with a quartzcrystal operably connected to a radio-frequency (RF) transceiver (notshown) that together function to transmit, receive and synchronize datastreams from the electronics unit 104. However, the input module can beconfigured in any manner that is capable of receiving data from theelectronics unit 104. Once the data stream is received, the input modulesends it to a processor that processes the data stream, such asdescribed in more detail below. The processor is the central controlunit that performs the processing, such as storing data, analyzing datastreams, calibrating analyte sensor data, estimating analyte values,comparing estimated analyte values with time corresponding measuredanalyte values, analyzing a variation of estimated analyte values,downloading data, and controlling the user interface by providinganalyte values, prompts, messages, warnings, alarms, and the like. Theprocessor includes hardware that performs the processing describedherein. Read-only memory (ROM) provides permanent or semi-permanentstorage of data, storing data such as a sensor ID, a receiver ID, andprogramming to process data streams (for example, programming forperforming estimation and other algorithms described elsewhere herein).Random access memory (RAM) stores the system's cache memory and is usedin data processing. An output module, which may be integral with and/oroperatively connected with the processor, includes programming forgenerating output based on the sensor data received from the electronicsunit (and any processing that incurred in the processor).

In some embodiments, analyte values are displayed on a display device.In some embodiments, prompts or messages can be displayed on the displaydevice to convey information to the user, such as reference outliervalues, requests for reference analyte values, therapy recommendations,deviation of the measured analyte values from the estimated analytevalues, or the like. Additionally, prompts can be displayed to guide theuser through calibration or troubleshooting of the calibration.

Additionally, data output from the output module can provide wired orwireless, one- or two-way communication between the receiver and anexternal device. The external device can be any device that interfacesor communicates with the receiver. In some embodiments, the externaldevice is a computer, and the receiver is able to download currentand/or historical data for retrospective analysis by a physician, forexample. In some embodiments, the external device is a modem, and thereceiver is able to send alerts, warnings, emergency messages, or thelike, via telecommunication lines to another party, such as a doctorand/or a family member. In some embodiments, the external device is aninsulin pen or insulin pump, and the receiver is able to communicatetherapy recommendations, such as an insulin amount and a time to theinsulin pen or insulin pump. The external device can include othertechnology or medical devices, for example pacemakers, implanted analytesensor patches, other infusion devices, telemetry devices, or the like.The receiver may communicate with the external device, and/or any numberof additional external devices, via any suitable communication protocol,including radio frequency (RF), Bluetooth, universal serial bus (USB),any of the wireless local area network (WLAN) communication standards,including the IEEE 802.11, 802.15, 802.20, 802.22 and other 802communication protocols, ZigBee, wireless (e.g., cellular)telecommunication, paging network communication, magnetic induction,satellite data communication, GPRS, ANT, and/or a proprietarycommunication protocol.

System Calibration

When a new sensor of a continuous blood analyte monitor is implanted, itis calibrated to convert an analog or digital signal directly related tothe measured analyte from the analyte sensor (e.g., current) toconcentration in clinical units for outputting meaningful data to auser. Calibration of commercially available glucose monitors typicallyinvolves obtaining one or more reference analyte values. A referenceanalyte value refers to an analyte value obtained from a self-monitoredblood analyte test. One such test is a finger stick test, in which theuser obtains a blood sample by pricking his or her finger, and tests thesample using any known analyte sensor. Where the analyte being sampledis glucose, the obtained value is referred to as a blood glucose (BG)value. The BG value is compared to a measurement of glucose taken by theimplanted sensor at substantially the same time as the finger sticksample was obtained. During the early stages after sensor implantation,it is expected that baseline and/or sensitivity values may changebetween sensor calibrations. Thus, as time passes after a calibrationusing one or more reference values, the resulting calculated sensorvalues (using a particular conversion function determined at thecalibration) may differ from substantially time-corresponding BG valuesdue to changes of the sensor and/or its surrounding environment. Thisphenomenon is referred to as “drift,” and is discussed in more detailbelow. To provide more accurate sensor values between calibrations,drift is preferably taken into consideration by applying appropriatecompensation.

A sensor's sensitivity to analyte concentration during a sensor sessioncan often change as a function of time. This change in sensitivity canmanifest itself as an increase in current for a particular level ofglucose. In some embodiments, the sensitivity increases during the first24-48 hours with a relative change in tens of percents. In order toprovide an accurate analyte concentration reading to a user, systemcalibrations using reference meters (e.g., strip based blood glucosemeasurements) may be needed. Typically, the rate of calibrations can be1, 2 or more calibrations a day.

In light of the foregoing, a first calibration of a newly implantedsensor is typically performed at a set interval after implantation. Thisinterval, which may be, for example, two hours, avoids calibratingduring a time when sensor readings are likely to be too inaccurate toprovide meaningful information. Subsequent calibrations are thentypically performed at set intervals, such as every four, six, twelve,twenty-four, thirty-six, forty-eight or seventy-two hours, for example.However, the analyte values displayed to the user by the continuousmonitor are updated much more frequently, such as, for example, everyfive minutes. Thus, to compensate for sensor drift that occurs betweencalibrations, a drift compensation function may be applied to theanalyte values calculated by the continuous monitor at regularintervals. That is, the drift behavior of the sensor over time can bemeasured or predicted and compensated for on a substantially continuousbasis. This concept is discussed in more detail below.

Time-Dependent Algorithms

As discussed above, the sensor outputs a signal in the form ofelectrical current. A conversion function is applied to the sensorsignal in order to produce a user output that the user understands asrepresentative of a concentration of analyte in his or her bloodstream.However, the proper conversion function to be applied can be dependentupon an elapsed time since the sensor was implanted. This phenomenon isdue to the fact that the sensor may undergo a time-dependent shift inbaseline and/or sensitivity after implantation, also referred to as“drift.” That is, the baseline and/or sensitivity of the sensor may havea different value at time t₀ (at or shortly after implantation) than attime t_(n) (at a given interval after time t₀). Using sensitivity as anexample, FIG. 2 illustrates the sensitivity, m, for a given sensor attime t₀, while FIG. 3 illustrates the sensitivity, m′, for the samesensor at time t_(n). A comparison of these figures shows that thesensitivity of the sensor (the slope of the curve) has increased fromtime t₀ to time t_(n). This behavior is typical of some continuousanalyte sensors in the early stages after implantation, and can bereferred to as “upward signal decay.” However, the sensor behaviorillustrated in FIGS. 2 and 3 is just one example. Drift can be eitherupward or downward, and may occur at either the beginning or end of asensor's lifespan.

FIG. 4 illustrates sensor sensitivity over time in one example sensor,which can be referred to as a sensitivity profile and/or a drift curve.As shown in Region 1 of the drift curve C toward the left-hand side ofthe graph, the rate of increase in sensor sensitivity is greatest in theearly stages after implantation. Region 1 typically spans the first dayup to about three days after sensor implantation, but could last moretime or less time. For example, Region 1 may span the first six, eight,ten, twelve, eighteen, twenty-four, thirty-six, forty-eight, seventy-twoor ninety-six hours after implantation. Eventually, the sensorsensitivity levels off, as shown in Region 2 of the drift curve C. Whilenot shown in FIG. 4, beyond Region 2 the sensor sensitivity begins todecrease as the sensor reaches the end of its usable life.

FIG. 5 illustrates the ideal compensation function for the sensitivityprofile, or drift curve, of FIG. 4. It is the ideal compensationfunction in the sense that it is the inverse of the drift curve of FIG.4. Thus, when the two curves are superimposed, as in FIG. 6, theyresolve to a straight horizontal line L, which exhibits no drift.

Due to sensor drift, application of the proper compensation functiondepends upon where the sensor is along the drift curve C in FIG. 4. Butthis factor cannot be determined with absolute certainty, due to thepossibility that a sensor may be reused. Typically, at the end of theintended use timeline for a given sensor, the sensor electronics stopthe sensor session and the user is instructed to replace the sensor.Hosts, however, often do not replace the sensor for a variety ofreasons, including a desire to avoid having to purchase new sensors.Also, a host may remove a sensor before it has reached the end of itslife cycle for a variety of reasons, such as a desire to avoid gettingit wet while bathing.

Thus, some hosts may restart an old sensor by, for example, pressing arestart button on the sensor electronics, detaching and reattaching thesensor electronics and/or by selecting to “start” a new session from amenu or another user interface-driven methodology. By restarting asensor that is already implanted, the sensor electronics are under thefalse assumption that the current sensor has just been implanted for thefirst time, when in reality it has been in the host's body for apotentially significant amount of time. Certain of the presentembodiments provide methods for determining whether the user hasimplanted a new sensor or restarted an old one. Certain others of thepresent embodiments provide methods for determining a propercompensation function to be applied to sensor data, taking into accountthe possibility that a recently implanted sensor may have beenrestarted. Certain others of the present embodiments provide methods forapplying a first compensation function to sensor data during a firstinterval, and applying a second compensation function to sensor dataduring a second interval after the first interval.

Certain of the present embodiments comprise systems and methods forprocessing sensor data of a continuous analyte sensor implanted within abody. With reference to FIG. 7, one embodiment of the present methodscomprises initializing the sensor, at B700, and determining whether thesensor has been previously used, at B702. If the sensor has not beenpreviously used, a first set of time-dependent algorithmic functions isapplied to an output of the sensor, at B704. If the sensor has beenpreviously used, a second set of time-dependent algorithmic functions isapplied to the output of the sensor, at B706. It should be noted thatalthough the time-dependent algorithmic functions may be applied to anoutput of the sensor, the time-dependent functions also may be appliedto any data associated with the sensor, including sensor values,reference glucose values, or the parameters in the linear model, forexample.

In one embodiment, determining whether the sensor has been previouslyused comprises determining a time, delta T, since the prior sensorsession ended and the current sensor session was initialized. If t isless than a threshold value, it is determined that the sensor has notbeen previously used. However, if t is greater than the threshold value,it is determined that the sensor has been previously used. In certainembodiments, initialization times can be stored in memory accessible bythe sensor electronics.

In some embodiments, determining whether the sensor has been previouslyused comprises measuring a change in impedance of the sensor over a timeT. With some sensors, it is expected that the impedance of the sensorwill change during the early stages after implantation, after which itwill level off. The impedance may increase or decrease, depending uponthe sensor's characteristics. Thus, if the measured impedance change isgreater than a threshold value, it is determined that the sensor has notbeen previously used. However, if the measured impedance change is lessthan the threshold value, it is determined that the sensor has beenpreviously used.

One aspect of determining whether the sensor has been reused may bedetermining the time since it was implanted. Thus, with reference toFIG. 7A, some embodiments of the present methods comprise initializingthe sensor, at B700. At B708, a first set of time-dependent algorithmicfunctions is applied to the output of the sensor, during a first timeinterval, based on the elapsed time since the sensor was implanted. AtB708, a second set of time-dependent algorithmic functions is applied tothe output of the sensor, during a second time interval after the firsttime interval, based on the elapsed time since the sensor was implanted.It should be noted that although the time-dependent algorithmicfunctions may be applied to an output of the sensor, the time-dependentfunctions also may be applied to any data associated with the sensor,including sensor values, reference glucose values, or the parameters inthe linear model, for example.

For example, after a sensor calibration is performed, a firstcompensation function may be applied to sensor data for a first timeinterval. At the end of the first time interval, another sensorcalibration is performed. That calibration may indicate that the firstcompensation function is no longer appropriate, because the sensorsignal has drifted. Thus, a second, more appropriate, compensationfunction may thereafter be applied to sensor data over a second timeinterval.

As discussed above, in alternative embodiments the sensor may benon-invasive. Thus, in such embodiments, a first set of time-dependentalgorithmic functions may be applied to the output of the sensor, duringa first time interval, based on the elapsed time since the sensor wasfirst initialized. Then, a second set of time-dependent algorithmicfunctions may be applied to the output of the sensor, during a secondtime interval after the first time interval, based on the elapsed timesince the sensor was first initialized. It should be noted that althoughthe time-dependent algorithmic functions may be applied to an output ofthe sensor, the time-dependent functions also may be applied to any dataassociated with the sensor, including sensor values, reference glucosevalues, or the parameters in the linear model, for example.

Initializing the Sensor

The present embodiments contemplate numerous techniques for initializingthe sensor. For example, initialization may be triggered when the sensorelectronics engages the sensor. In another example, initialization maybe triggered by a mechanical switch, such as a switch (not shown) on asnap-in base that receives the sensor electronics. When the sensorelectronics are snapped into the base, the switch is automaticallytripped. In another example, initialization may be menu driven, as theuser may be prompted by a user interface to begin initialization bymaking a selection on the user interface, such as by pushing a button ortouching a designated area on a touch screen. In another exampleinvolving a non-invasive sensor that is applied to the wearer's skin,the sensor may sense when it is in contact with skin and startautomatically.

Determining Whether the Sensor has been Previously Used

The present embodiments contemplate numerous techniques for determiningwhether the initialized sensor is a new sensor, i.e. one that has neverbeen used before, or a previously used sensor that has been restarted.

In some embodiments, the system is programmed to algorithmicallyidentify a new sensor insertion by looking for changes in signalcharacteristics (e.g., a spike indicating a break-in period, no changein sensor count values during the first hour, or the like). Thefrequency or spectral content of the raw signal can be analyzed, forexample, to identify electrochemical break-in, and the like.

Another technique may rely on an elapsed time since a previous sensorwas removed from the body. The longer the interval between a firstsensor being removed and second sensor being implanted, the more likelyit is that the second sensor is new.

To measure this interval, the sensor electronics may include hardwareand/or circuitry to detect removal of a first (previous) sensor at timet₀, implantation of a second (subsequent) sensor at time t_(n) (wherethe first and second sensors may be the same sensor), and a timerconfigured to measure the time elapsed between time t₀ and t_(n). Thetimer may be started upon detection of the removal of the first sensor,and stopped upon detection of implantation of the second sensor. Theelapsed time may then be used to determine whether the second sensor isa new sensor or not.

In some embodiments, the system may rely on user input. For example,when a new sensor is implanted, or an old sensor is restarted, a newsensor session begins. When a user begins a new sensor session, he orshe may be prompted to confirm whether or not the sensor is new. Theprompt may comprise, for example, a question presented on a graphicaluser interface.

In some embodiments, the system may require the input or reading of aunique identifier for the sensor. For example, when a user begins a newsensor session, he or she may be prompted to input a unique serialnumber associated with the sensor into the user interface. The systemmay be configured to allow only one use of each sensor, so that if theserial number input by the user has been previously input, the sensorelectronics may determine that that sensor has been previously used. Insuch a situation, the sensor electronics may be programmed to notinitiate a new sensor session until a new sensor is implanted. Usedsensors would thereby be rendered inoperable, because they could not bereused with the sensor electronics.

In an alternative embodiment, each sensor may include a uniqueidentifier that the sensor electronics can read without any need foruser input, such as a radio frequency identifier (RFID). When a newsensor session begins, a reader associated with the sensor electronicsmay read the RFID in order to determine whether a sensor with the sameRFID has been previously used. Again, if the sensor has been previouslyused the sensor electronics may not initiate a new sensor session untila new sensor is implanted.

In some embodiments, the system may compare a calibration line of thesensor with a calibration line of a most recently used sensor. Forexample, when a new sensor session begins an initial calibration of thesensor is performed. At that time, the user may be prompted by the userinterface to input one or more reference analyte values into the sensorelectronics. These reference analyte values are used to determine acalibration line for the new sensor session. The new calibration line isthen compared to a calibration line drawn at the end of the previoussensor session (old calibration line). If the old and new calibrationlines substantially correspond, it is highly probable that the sensorwas restarted.

In some embodiments, the system may compare a signal from the sensorwith a signal from a most recently used sensor, particularly if a shortperiod of time elapses in between sensor removal and implantation. Forexample, and with reference to FIG. 8, the curve C₁ represents thesensor signal from a mature sensor, i.e. one that has been implanted fora sufficient length of time that its signal does not exhibit substantialdrift. The sensor is removed at time t. Shortly thereafter, at time t′,a “new” sensor is implanted, and its signal is shown by the curve C₂.This sensor signal corresponds to that of the removed sensor, in that italso does not exhibit substantial drift. It is thus highly probable thatthe old sensor was restarted, because new sensors typically exhibitsubstantial drift in the early stages after implantation.

FIG. 9, by contrast, illustrates a comparison between the signals from aremoved sensor and a new sensor. The curve C₁ again represents thesensor signal from a mature sensor. The sensor is removed at time t.Some time thereafter, and after a longer interval than that illustratedin FIG. 8, at time t′, a new sensor is implanted, and its signal isshown by the curve C₂. Because the new sensor has not been reused, itssignal exhibits the upward drift that is characteristic of new sensors.

In some embodiments, the system may measure impedance to detect settlingof the sensor that results from electrochemical break-in of analyte tothe sensor. As used in this application, the term impedance includesresistance, reactance, or any parameters derived from resistance andreactance, such as phase, and may be measured at different frequenciesof current. As discussed above, upon implanting a new sensor tissuebegins to grow around and within the sensor. As this tissue ingrowthproceeds, impedance of the sensor may increase or decrease. Thus, todetermine whether an implanted sensor is a new sensor or one that isbeing reused, some embodiments apply one or more stimulus signals to thesensor to determine its impedance. As discussed further below, astimulus signal may be any signal (e.g., any time-varying orspatial-varying quantity, such as an electric voltage, current or fieldstrength) applied to the sensor to elicit a response. Non-limitingexamples of stimulus signals that can be used in the embodimentsdescribed herein can be a waveform including one or more of: a stepincrease in voltage of a first magnitude, a step decrease in voltage ofa second magnitude (where the first and second magnitudes can be thesame or different), an increase in voltage over time at first rate, agradual decrease in voltage over time having a second rate (where thefirst rate and the second rate can be different or the same), one ormore sine waves overlayed on the input signal having the same ordifferent frequencies and/or amplitudes and the like. A response to thestimulus signal can then be measured and analyzed (the response is alsoreferred to herein as the “signal response”). Based on the calculatedimpedance value, a determination can be made as to whether the sensor isnew or not based on an expected impedance value for a new sensor.

FIG. 10 is a flowchart illustrating a process 1000 for determining animpedance of a sensor in accordance with the present embodiments. Atstep 1002, a stimulus signal in the form of an alternating current (ac)voltage at a given frequency is applied to a working electrode of thesensor being studied. The ac voltage can be overlayed on a biaspotential and can be relatively small as compared to the bias potential,such as voltage that is in the range of about 1% to 10% of the biasvoltage. In one embodiment, the ac voltage is a sine wave having anamplitude in the range of 10-50 mV and a frequency in the range ofbetween about 100 Hz-1 kHz. The sine wave can be overlayed on a 600 mVbias voltage. The response signal (e.g., in units of current) can thenbe measured in step 1004 and analyzed in step 1006 to determine animpedance at the given frequency. Should the impedance of the sensor ata range of frequencies be of interest, the process 1000 can be repeatedby applying an ac voltage at each frequency of interest and analyzingcorresponding output responses.

FIG. 11 is a flowchart illustrating a process 1100 for determining animpedance or plurality of impedances of a sensor being studied byapplying one or more stimulus signals and converting the response signalor signals to a frequency domain in accordance with the presentembodiments. The data can be converted to the frequency domain using aFourier transform technique, such as a fast Fourier transform (FFT),discrete time Fourier transform (DTFT) or the like. At step 1102, astimulus signal in the form of a voltage step can be applied to a biasvoltage of the sensor. The voltage step can be in the range of 10-50 mV,for example 10 mV, and the bias voltage can be 600 mV. The signalresponse can then be measured and recorded (e.g., an output current) atstep 1104, and a derivative of the response can be taken at step 1106.At step 1108, a Fourier transform of the derivative of the response canthen be calculated to yield ac currents in the frequency domain. One ormore impedances of the sensor over a wide spectrum of frequencies canthen be calculated based on the ac currents at 1110.

FIG. 12 is a flowchart illustrating a process 1200 for determining animpedance of a sensor being studied, such as the impedance of thesensor's membrane, in accordance with the present embodiments. At step1202, a stimulus signal in the form of a voltage step above a biasvoltage is applied to the sensor. The signal response is measured atstep 1204, and, at step 1206, a peak current of the response isdetermined. Next, at step 1208, impedance (e.g., resistance) of thesensor membrane (e.g., R_(membrane)) is calculated based on the peakcurrent. In an alternative embodiment, instead of calculating a sensorimpedance based on the peak current, the peak current can be correlatedto one or more predetermined sensor relationships to determine aproperty of the sensor, such as the sensor's sensitivity.

The relationship between a signal response resulting from a stimulussignal in the form of a voltage step and a sensor membrane resistance ofembodiments of analyte sensors will now be discussed further withreference to FIGS. 13A and 13B. FIG. 13A is a graph of an input voltage1300 applied to an analyte sensor over time in accordance with thepresent embodiments. The input voltage 1300 applied to the analytesensor initially corresponds to the bias voltage, which in oneembodiment is about 600 mV. A stimulus signal in the form of a voltagestep is then applied to the input voltage at time t₁. The magnitude ofthe voltage step, Δv, can be in the range of 10-50 mV, for example 10mV.

FIG. 13B is a graph of a current response 1302 of the analyte sensor tothe input voltage 1300 of FIG. 13A. As illustrated in FIG. 13B, thecurrent response 1402 can include a sharp spike in current starting attime t₂, which corresponds to the time in which the voltage step beginsto impact the response. The current response 1302 includes a peakcurrent at point 1304 and then the current response 1302 graduallydecreases and levels off to a slightly higher level due to the increasein input voltage 1300 as compared to before the voltage step.

In one embodiment, a change in current, Δi, measured as the differencebetween the magnitude of the current response 1302 prior to the voltagestep and the peak current 1304 resulting from the voltage step, can thenbe used to estimate the sensor membrane resistance, such asR_(membrane). In one embodiment, an estimated sensor membrane resistancecan be calculated using Ohms Law, whereR _(membrane) =Δv/Δi

As discussed above, Δv is the step voltage increase and Δi is the changein current response due to the step voltage increase.

In certain embodiments, two or more of the foregoing methods fordetermining whether a sensor has been previously used may be usedtogether. For example, elapsed time between sensor removal andimplantation may be used together with comparing sensor signals. If ashort time elapses between sensor removal and implantation, and thesignal from the implanted sensor is substantially identical to thesignal from the removed sensor, it is highly likely that the old sensorwas restarted. In another example, comparing sensor calibration linesmay be used together with comparing sensor signals. Again, if both thecalibration lines and the sensor signals are substantially identical forthe old and new sensors, it is highly likely that the old sensor wasrestarted. In another example, measuring impedance may be used togetherwith comparing trends in sensor signals. Any of the present methods maybe used in combination with any other of the present methods, and anygiven combination may include two or more distinct methods, such asthree or four methods in combination. As more and more methods arecombined, the probability of correctly determining whether a sensor isnew or has been restarted increases when the results of each method arein agreement.

Various methods may be used to combine the results of multiple methodsfor determining whether a sensor is new or has been restarted. Examplesinclude weighted averaging and fuzzy logic. These methods are wellknown, and will not be further elaborated upon here. Another examplemethod is decision fusion. Decision fusion provides a statistical modelthat combines information from multiple tests and takes into account theperformance of each “detector” for prediction of sensor restart.Decision fusion requires that binary decisions (“yes” or “no”) are madeindependently at each detector. These decisions are fused (multiplied)in the form of likelihood values that depend only on the knownperformance (sensitivity and specificity) of each detector. The resultis a fused set of likelihood values that can be compared to a thresholdto make a final decision.

The true case of “yes” (sensor restart) is given as H₁, and the truecase of “no” (new sensor) is given as H₀ (i.e. the null hypothesis).Decisions are made for each test (d=1 or d=0) and it is known fromprevious work what the sensitivity and specificity is for each test.Each decision is then converted to a likelihood value, λ:

${\lambda(d)} = {\frac{P( {d❘H_{1}} )}{P( {d❘H_{0}} )}.}$

The likelihood value is the probability of making a decision in the casethat the sensor has been restarted, divided by the probability of makinga decision in the case that the sensor has not been restarted. For adecision of “yes,” or 1, the likelihood value is the probability ofdetection (Pd) divided by the probability of a false alarm (Pf):

${\lambda(d)} = {\frac{P( {d❘H_{1}} )}{P( {d❘H_{0}} )} = \{ {\begin{matrix}\frac{Pd}{Pf} & {{{if}\mspace{14mu} d} = 1} \\\frac{1 - {Pd}}{1 - {Pf}} & {{{if}\mspace{14mu} d} = 0}\end{matrix}.} }$

For a test with a high probability of detection and a low probability offalse alarm, λ will be very high for a decision of 1 and very small fora decision of 0. This is how the weighting of each decision based ontest performance comes in. Once each decision is converted to alikelihood value, all the likelihood values are simply multipliedtogether and the final likelihood value is compared to a threshold tomake the final decision.

In some embodiments, the system may apply a voltage to the sensor at theend of a sensor session. The voltage may be high enough to render thesensor in a state in which it is known that the sensor has reached anend of a sensor session. Thus, if the user tries to reuse that sensor,the system will know that the sensor is being reused.

In some embodiments, the system may use sensitivity information (e.g., asensitivity coefficient (SC) and/or calibration line) from the end ofprevious sensor session to determine an expected or estimated glucosevalue (EGV) at the beginning of a subsequent sensor session. Then, theuser obtains his or her blood glucose (BG) through a finger stick, orother equivalent method, and the EGV and BG are compared (i.e., at thestartup of the subsequent sensor session). If the user had actuallyinserted a new sensor (rather than attempting to reuse a sensor), thenwith certain sensor designs that exhibit sensor drift, the EGV shouldnot correspond to the BG because the sensitivity from the end of aprevious sensor session should not be the same as the sensitivity fromthe beginning of a subsequent sensor session, for example, such asdescribed with respect to FIG. 4. Accordingly, if the difference betweenthe BG and the EGV is within a predetermined tolerance, it may bedetermined that the sensor has been reused, because for sensor designsthat exhibit drift in the early stages after implantation the differencebetween the BG and the EGV should not be within the predeterminedtolerance.

In some embodiments, the system may project a future EGV using a glucosetrend from the last previous session. The projection may be, forexample, at most fifteen minutes into the future. An EGV at the samepoint in time in the future is then calculated for the current sessionusing a first SC. An error between the projected EGV and the EGV of thenew session is then calculated. If the error is within a predeterminedtolerance, it may be determined that the sensor has been reused, becausefor sensors that exhibit drift in the early stages after implantationthe error between the projected EGV and the EGV of the new sessionshould not be within the predetermined tolerance.

Applying Time-Dependent Algorithmic Functions Based Upon Determinationof Elapsed Time Since Implantation

Referring again to FIG. 7A, once the sensor has been implanted andinitialized (B700), an appropriate time-dependent algorithmic function,or functions, is/are applied to the sensor data. In this embodiment,first and second function(s) (B708, B710, respectively) to be appliedis/are based on the elapsed time since the sensor was implanted, andoptionally on a determination as to whether the sensor is new or hasbeen reused.

In one embodiment, drift compensation may be applied based on an elapsedtime since implantation, for example where the drift compensation takesinto account where along the drift curve (e.g., sensitivity curve) thesensor is. For example, it may be determined that the sensor was in usefor one day. The applied drift compensation would take the one day ofuse into account and apply a drift compensation function that wouldnormally be applied to a one day old sensor, rather than one that wouldbe applied to a new sensor. Accordingly a first drift compensationfunction (or parameter of that function) is applied at a first elapsedtime since implantation and a second drift compensation function (orparameter of that function) is applied at a second elapsed time sinceimplantation.

In some embodiments, the conversion function may be adaptive andcomprise two or more different conversion functions, or parametersapplied to the conversion function, adaptively applied based on elapsedtime since implantation. In one such embodiment, the conversion functionmay include one or more assumed parameters and/or boundaries, which havevalues that are dependent on the elapsed time since implantation.

In one example embodiment, the applied conversion function includespredetermined baseline information, which may include a scaling factorto be applied to a calculated or measured baseline, a priori baselineassumptions to be applied to a conversion function, and/or the like,wherein the predetermined baseline information adapts, at least in part,based on elapsed time since implantation. Accordingly, first baselineinformation (a first algorithmic function) is applied at a first timeand second baseline information (a second algorithmic function) isapplied at a second elapsed time since implantation. For example, it maybe assumed that a sensor has a higher or lower baseline on day threethan it does on day one. Thus, once the age of the sensor is known, theapplied conversion function may adjust the baseline accordingly. Inanother example embodiment, the applied conversion function may besubject to boundary tests, such as described in more detail below,wherein the boundaries adapt, at least in part, based on elapsed timesince implantation. Accordingly, at a first time after implant, firstboundary conditions are provided by the first time-dependent algorithmicfunction and second boundary conditions are provided by the secondtime-dependent algorithmic function.

FIG. 14 is a graph that illustrates one example of using priorinformation for slope (sensitivity) and baseline. The x-axis representsreference glucose data (blood glucose) from a reference glucose sourcein mg/dL. The y-axis represents sensor data from a transcutaneousglucose sensor of the present embodiments in counts (a count is a unitof measurement of a digital signal, which is derived from current from aworking electrode of the transcutaneous glucose sensor, in someembodiments). An upper boundary line 1400 is a regression line thatrepresents an upper boundary of “acceptability” in this example. A lowerboundary line 1402 is a regression line that represents a lower boundaryof “acceptability” in this example. The boundary lines 1400, 1402 wereobtained from retrospective analysis of in vivo sensitivities andbaselines of glucose sensors as described with respect to the presentembodiments. As described above, the boundary lines 1400, 1402 canadaptively adjust, or change, based on the elapsed time sinceimplantation; namely, taking into consideration an expected change in aconversion function over time during implantation associated withchanges in baseline and/or sensitivity thereof.

A plurality of matched data pairs 1404 represents data pairs in acalibration set obtained from a glucose sensor as described with respectto the present embodiments. The matched data pairs are plotted accordingto their sensor data and time-corresponding reference glucose data. Aregression line 1406 represents the result of regressing the matcheddata pairs 1404 using least squares regression. In this example, theregression line falls within the upper and lower boundaries 1400, 1402,thus indicating that the sensor calibration is acceptable. The number ofmatched data pairs chosen for inclusion in this calibration set may bedependent on elapsed time since implantation, for example, fewer matcheddata pairs when the conversion function is changing at a faster rateduring the first few days after implant, and more matched data pairswhen the conversion function is more stable after those first few days.

In some embodiments, if the slope and/or baseline fall outside thepredetermined acceptable boundaries described above, which would beillustrated in this graph by a line that crosses the upper and/or lowerboundaries 1400, 1402, then the system is configured to assume abaseline value and re-run the regression (or a modified version of theregression) with the assumed baseline, wherein the assumed baselinevalue is derived from in vivo or in vitro testing. As described above,this assumed baseline may be adaptive based on elapsed time sinceimplantation, for example, a first value on day one, a second value onday two, a third value on day three, or the like. Subsequently, thenewly derived slope and baseline are again tested to determine whetherthey fall within the predetermined acceptable boundaries. Similarly, theprocessing continues in response to the results of the boundary test. Ingeneral, for a set of matched pairs (e.g., calibration set), regressionlines with higher slope (sensitivity) have a lower baseline andregression lines with lower slope (sensitivity) have a higher baseline.Accordingly, the step of assuming a baseline and testing againstboundaries can be repeated using a variety of different assumedbaselines based on the baseline, sensitivity, in vitro testing, and/orin vivo testing. It is preferred that after about two iterations ofassuming a baseline and/or sensitivity and running a modifiedregression, the system assumes an error has occurred (if the resultingregression lines fall outside the boundaries) and fail-safe. The term“fail-safe” includes modifying the system processing and/or display ofdata responsive to a detected error to avoid reporting of inaccurate orclinically irrelevant analyte values.

As described above, time-dependent boundaries may be applied to theconversion function to provide any number of different algorithmicfunctions to be applied at any given time after implant. For example,upper and lower boundaries may be applied to limit the conversionfunction, where the upper and lower boundaries change over time. It isknown, for example, that for some sensors sensitivity rises during thefirst day to three days after implantation, and eventually levels off.It is also known that for some sensors the slope of the sensor driftcurve is greatest shortly after implantation, and gradually decreases.Accordingly, the time-dependent algorithmic functions in this case arethe boundaries (e.g., lines) that delineate acceptable slopes andbaselines of the conversion function. The boundaries may be obtained,for example, from retrospective analysis of in vivo sensitivities and/orbaselines of analyte sensors. As this example illustrates, applied apriori knowledge doesn't have to be static. Rather, it can change overtime in response to expected and/or measured changes in a givenparameter and/or time. Further, applying a priori knowledge dynamicallyis not limited to the conversion function itself. Namely, adaptivetime-based parameters could be applied to any data or processingassociated with processing of the continuous analyte data, includingsensor sensitivity, sensor baseline, matched data pairs, drift of thesensitivity or baseline over time, etc. For example: boundaries forallowable sensitivity values may change dependent on elapsed time sinceimplantation; boundaries for allowable baseline values may changedependent on elapsed time since implantation; boundaries for allowabledeviations of matched data pairs may change based on elapsed time sinceimplantation; boundaries for allowable drift of the sensitivity overtime may change based on elapsed time since implantation; and boundariesfor allowable drift of baseline over time may change based on elapsedtime since implantation. By “change,” it is meant that the allowableboundaries may increase, decrease, tighten in range or loosen in range,for example. The adaptive values may change daily in a step-wise fashionor continuously based on a curve or function as may be appreciated byone skilled in the art.

In some embodiments, the number of matched data pairs in the calibrationset changes depending upon the elapsed time since implantation asdiscussed above. For example, for sensors where sensor sensitivity isknown to rise during the first day after implantation, and eventuallylevels off, fewer, or only more recent (e.g., last 1, 2, or 3), matcheddata pairs may be used in the calibration set during the interval wheredrift is severe, such as for example ±20%, 10%, 5%, 3%, 2%, 1%. In thisembodiment, older data pairs, which are not truly representative of thecurrent state of the sensor due to the severe drift, are discarded sothat they do not negatively affect the accuracy of the appliedcompensation function. By contrast, as the sensor matures and driftlevels off, more matched data pairs may be used in the calibration set(e.g., 3, 4, 5, 6, 7, 8 or more).

In some embodiments, fewer sensor calibrations, for example requests forreference data from the user, may be made when drift is minor ornonexistent. Again, it is known that sensor sensitivity rises during thefirst day after implantation, and eventually levels off. Thus, after thesensitivity levels off there is less of a need for sensor calibrations.If a threshold number of calibrations consistently reveal that little orno drift is occurring, future calibrations may be omitted, or afrequency of calibrations reduced.

In some embodiments, error detection or fail-safes may includeparameters that are dependent upon elapsed time since implantation, forexample, error detection and/or fail-safes may apply a first set ofrules (e.g., more liberal) on day 1 vs. a second set of rules (e.g.,more stringent) on days 2 and following. As one example, outlierdetection parameters may change over time. An outlier is a referencedata point that is very far away from a calculated sensor glucose value(e.g., in a matched data pair). Outlier detection may be applied to rawsensor data, calculated (calibrated) sensor data or both. These datapoints may be discarded, but over time the criteria for deciding whatconstitutes an outlier may change. For example, early on after sensorimplantation, fewer data points may be classified as outliers, becausethe sensor is undergoing a large amount of drift. Over time, as driftlevels off, reference data points may be more liberally discarded evenwhere they have less variation from sensor glucose value than datapoints that may not have been discarded earlier in the sensor lifecycle.

Any of the above adaptive parameters or processes may be used alone orin combination dependent on the elapsed time since implantation and mayfurther be dependent upon other inputs, such as drift, for example,which is discussed in more detail elsewhere herein.

Drift Compensation

With reference to FIG. 15, some embodiments of the present methodscomprise measuring a change in sensitivity or baseline of a sensor overa time interval, at B1500. It is then determined what drift compensationfunction is to be applied to a plurality of time-spaced data pointsoutput by the sensor, at B1502, and the drift compensation function isthen applied continuously (e.g., iteratively) to the data points, atB1504.

In some embodiments, the drift compensation function may be applied notonly to the data points output by the sensor, but also to a calibrationset (calset) that the sensor uses to produce the data points. The calsetis the set of matched pairs of sensor counts to blood glucose valuesobtained at substantially the same time as each count. The calset isused to draw a calibration line. In these embodiments, the driftcompensation function is applied to the sensor counts to scale thosecounts. For example, the following formula may be used:Counts'=(1+Adjustment)*Counts. The calibration line is then redrawnusing the adjusted Counts' values. The counts may be adjusted in realtime or retrospectively, for example.

Measuring a Change in Sensitivity and/or Baseline of a Sensor Over aTime Interval

In one embodiment, a current sensitivity and/or baseline value of asensor is compared to a previous sensitivity and/or baseline value ofthe sensor. For example, a first measured sensitivity or baseline of thesensor may be taken at a beginning of a time interval, and a secondmeasured sensitivity or baseline of the sensor may be taken at an end ofthe time interval. The first and second measured sensitivities orbaselines are then compared to determine whether the sensitivity isincreasing, decreasing, or remains stable. The sensitivity may bemeasured periodically to track a rate of change of the sensitivity. Therate of change can then be used to determine an appropriate driftcompensation to be applied to data from the sensor. Measurements may betaken at intervals of any length, such as, for example, every twelvehours.

In some embodiments, the measured change in sensitivity or baseline ofthe sensor is based on a seed value. A seed value is a predeterminedquantity or rate. In the present embodiments, the seed value would thusbe a predetermined sensitivity or baseline value or rate of change valueof the sensor at time t₀. For example, a sensitivity or baseline of anew sensor prior to implantation may be known from, for example,experimental data, product testing, etc., and may be based on a measuredabsolute impedance of the sensor. The impedance of the sensor, which maybe calculated at multiple frequencies, may be measured in vitro or invivo, and more than one frequency may need to be tested. Also, a typicaldrift pattern for the sensor may be known from, for example,experimental data, product testing, etc. Comparing a measuredsensitivity or baseline of the sensor at time t₀ with the predeterminedsensitivity or baseline at time t₀ provides an estimation of the changein sensitivity or baseline over the interval from t₀ to t_(n). A driftcompensation function to be applied to data output from the sensor canthen be determined based on the estimated change in sensitivity orbaseline. The drift compensation function to be applied is thus based,at least in part, on the predetermined sensitivity or baseline. A valueof the predetermined sensitivity and/or baseline may be encoded onelectronics associated with the sensor, for example, encoded on sensorpackaging (e.g., a cell phone readable QR code, or the like). Inaddition, other values and/or functions may be encoded on the sensorelectronics, such as one or more predicted plateaus, one or morepredicted profiles, one or more compensation functions, one or moredrift curves, in vitro data, etc.

In some embodiments, the seed value may be generic, or independent ofknown characteristics of the body in which the sensor is implanted. Inalternative embodiments, the seed value may be assigned according toknown characteristics of the body in which the sensor is implanted. Thecharacteristics may include, for example, at least one of age, bodytype, e.g., BMI or percentage body fat, gender, diabetes type, diabetesduration, concomitant diseases (e.g., diabetic nephropathy) and/orsensor location.

In some embodiments, sensitivity seed values may be used to correctand/or direct parameters in the applied compensation function, which isdescribed in more detail elsewhere herein, including drift envelopedrift rates (e.g. the max correction rate that can be applied in a giventime window), start time of compensation (e.g. the time after sensorinsertion that the drift compensation function starts), end time of thedrift compensation function, start time of the different time windows inthe drift envelope, length of time windows (steps in a stepwisefunction), or the like, which may be adaptive based on a seed value, ameasured drift rate, reliability information, or the like. For example,multiple compensation functions may be available to choose from, and theselection may depend upon the sensitivity seed value. The sensitivityseed value can, in one example, provide the a priori drift rate ormagnitude information. The multiple compensations functions may becreated to span a range around the seed value. For example, if the seedvalue for drift magnitude is 50% then the compensation functions couldbe created with drift magnitudes of 40, 45, 50, 55, and 60% driftmagnitudes. In some embodiments, the base compensation function is basedon an exponential function or logarithmic function and the multiplecompensation functions are generated with a range of time constantsindicative of an amount of time for the sensor response to reach somefraction of its stable baseline or sensitivity. For example, if a sensortypically reaches 90% of its final sensitivity within 24 hours thencompensation functions could be generated with time constants of 20, 22,24, 26, and 28 hours. Multiple compensation functions may be derivedfrom in vitro testing, or prior in vivo sessions of a given host.Sensitivity seed values may be determined from prior in vitro testingand/or in vivo testing of sensors on the same host or a similar group ofhosts. In one example, sensitivity information from a previous sensorsession with a single host is transferred and applied as a seed value tosubsequent sensor session(s) of the same host. In some embodiments, theseed value may change based on the sensitivity calculated by thealgorithm at the initial calibration. In some embodiments, the seedvalue may be changed based on the sensitivity value at a calibration.

In some embodiments, a seed value may be encoded on electronicsassociated with the sensor. For example, some sensors may have knowndrift profiles and/or known initial sensitivities. Such sensors mayinclude calibration code that includes the appropriate compensationfunction to be applied to compensate for the known drift profile and/orknown initial sensitivity. Drift profiles and/or known initialsensitivities may be determined by an in vitro drift simulation test, orbased on actual in vivo testing of similar sensors. In vitro driftsimulation tests may be configured to modulate glucose in vitro tosimulate in vivo glucose patterns, or the like.

In some embodiments, the measured change in sensitivity or baseline ofthe sensor is compared to a priori knowledge in order to determinewhether a new sensor has been implanted or an old sensor has beenrestarted. For example, some new sensors exhibit a characteristic upwardsignal drift in the first few days after implantation, and some newsensors exhibit a characteristic downward signal drift in the first fewdays after implantation. Thus, in sensors that exhibit upward ordownward drift, if a measured change in sensitivity of that sensor showsthe expected drift (upward or downward), then it is likely that thesensor is new. But, if the measured change in sensitivity of that sensorshows no drift, or drift in the direction opposite from that expected,then it is likely that the sensor has been restarted. A priori knowledgecan also be used to detect other conditions besides sensor restart, suchas whether or not a sensor is faulty, for example.

In one example, drift rate is calculated by taking the differencebetween an estimated blood glucose value (EGV) and a reference bloodglucose value (BG), and dividing the result by the time since thecontinuous blood glucose monitor was last calibrated. EGV is based onsensor data that has already been converted using a previous calibration(conversion function). The BG value is obtained with a self-monitoringtest, such as a finger stick. As with previous examples, the calculateddrift rate may be bound by a priori knowledge and may change over timeas described in more detail elsewhere herein. For example, over time thedrift rate for a newly implanted sensor that exhibits characteristicdrift should decrease. Thus, if a drift rate calculation indicates thatthe drift rate is not decreasing, it may be determined that the sensorhas been restarted, or is faulty. It is noted that the drift rate may becalculated only when the last calibration was at least 2, 3, 4 or morehours previous to the current calibration in some embodiments due to theslow change of drift.

In another example, drift rate may be filtered or smoothed, for exampleestimated based on a weighted average of a current drift rate and atleast one previous drift rate. This example can be illustrated as:drift_(estimate)=(1−n)drift_(old) +n(drift)_(measurement)

In the above equation, n is a “forgetting factor”, n may vary between 0and 1, and its value dictates how fast old measurements are forgotten bythe model. For values of n close to 1, the model adapts more quickly torecent measurements. For values of n close to 0, the model adapts moreslowly to recent measurements. The value of n may depend on the elapsedtime since the sensor was implanted. The calculation may be recursive ornon-recursive. While a fixed forgetting factor n may be used, in someembodiments the forgetting factor n may be adaptive in real-time basedon the calculated drift rate. For example, adaptive adjustment of theforgetting factor n may be based on a metric indicative of how much ofthe total error in the system is due to drift. If most of the error isdue to drift, then our drift estimate is may be too aggressive or notaggressive enough, so the forgetting factor in the adaptive adjust (e.g.Drift_(estimate)) should be closer to 1, resulting in quicker adjustmentof the time series. If the most of the error is random then there is noneed to update Drift_(estimate) so the forgetting factor in the adaptiveadjust (e.g. Drift_(estimate)) should be closer to 0. One metric usefulfor determining much of the total error in the system is due to drift isto determine a ratio of the relative error (e.g., smoothed error) atcalibration to the absolute error at calibration, and use an absolutevalue of that ratio for n (or to determine n). In the initialcalculation of the ratio RelativeError and AbsoluteError may use seedvalues, after which the previous estimate may be used in the followingequations:RelativeError_(N)=Beta*ErrorAtCal+(1−Beta)*RelativeError_(N-1) andAbsoluteError_(N)=Beta*|ErrorAtCal|+(1−Beta)*AbsoluteError_(N-1), whereBeta is a forgetting factor for these equations.

In certain of the present embodiments, drift rate is calculated onlyafter a minimum amount of time has passed since the sensor wasinitialized. As discussed above, it is known that new sensors outputunpredictable readings in the early stages after implantation. Thisbehavior is due to the fact that penetration of fluid and tissue to thesensor does not happen immediately upon implantation. Rather, the sensor“settles” with its surroundings. Readings taken during this settlingperiod may be subject to random error, and may therefore be unreliable.These readings are preferably disregarded because drift error ispreferably greater than random error in order to accurately determine adrift compensation function to apply to sensor data. In one example, theminimum amount of time that preferably passes after sensorinitialization is three hours. However, the minimum amount of time maybe any amount of time, including less than three hours and more thanthree hours.

In some embodiments, changes in impedance of the sensor, or anymeasurable response to a stimulus signal, may be used to track changesin sensitivity of the sensor. A relationship between sensitivity andimpedance has been observed in some analyte sensors. Although notwishing to be bound by theory, embodiments of analyte sensors arebelieved to have a relationship between an impedance of a sensor'smembrane and the diffusivity of the membrane. For example, a change inimpedance of an analyte sensor can indicate a proportional change indiffusivity of the analyte sensor's membrane. Further, an increase indiffusivity can yield an increased transport of the analyte beingmeasured (e.g., glucose) through the membrane, resulting in an increasedsensor output current. That is, a change in diffusivity can result in aproportional change in sensor sensitivity. Other factors may alsocontribute to changes in sensitivity apart from just changes indiffusivity of the sensor membrane, depending upon the characteristicsof sensor and the environment in which the sensor is used.

A relationship between sensitivity and impedance can be used to estimatea sensor sensitivity value and/or correct for sensitivity changes of thesensor over time, resulting in increased accuracy, a reduction inrequired calibrations or both. In addition to detection of sensitivity,some embodiments can detect other characteristics of an analyte sensorsystem based on measurements of electrical impedance over one or morefrequencies. These characteristics include, but are not limited to,temperature, moisture ingress into sensor electronics components andsensor membrane damage.

In some embodiments, a relationship between a sensor's impedance and thesensor's sensitivity can be used to calculate and compensate forsensitivity changes of an analyte sensor. For example, a change inimpedance of an analyte sensor can correspond to a proportional changein sensitivity of the sensor. In addition, an absolute value of animpedance of an analyte sensor can correspond to an absolute value ofthe analyte sensor's sensitivity and the corresponding sensitivity valuecan be determined based on a predetermined relationship determined fromprior studies of similar sensors. Sensor data can then be compensatedfor changes in sensitivity based on an impedance to sensitivityrelationship.

FIG. 16 is a flowchart illustrating a process 1600 for compensatingsensor data for changes in sensitivity in accordance with the presentembodiments. At step 1602, a stimulus signal is applied to the sensorthat can be used to determine an impedance of the sensor's membrane. Thestimulus may be, for example, a signal having a given frequency, asdiscussed with respect to FIG. 10, or a voltage step, as discussed withrespect to FIGS. 11-13. A response to the input signal is then measuredat step 1604 and an impedance of the sensor's membrane is calculatedbased on the response at step 1606. Next, at step 1608, the calculatedimpedance is compared to an established impedance-to-sensor sensitivityrelationship. The established relationship can be determined from priorstudies of analyte sensors that exhibit similar sensitivity-to-impedancerelationships as the analyte sensor currently under test, for example,sensors that were made in substantially the same way under substantiallythe same conditions as the sensor currently under test. At step 1610, asensor signal (e.g., in units of electrical current or counts) of thesensor currently under test is corrected using the impedance tosensitivity relationship. An estimated analyte concentration value orvalues is then calculated based on the corrected sensor signal at step1612 using, for example, a conversion function. The estimated analyteconcentration values can then be used for further processing and/oroutputting, such as displaying information representative of theestimated values on a user device and/or outputting the information toan external device.

It should be understood that the process 1600 is only one example ofusing an impedance of a sensor to compensate for changes in sensorsensitivity, and that various modifications can be made to the process1600 that fall within the scope of the present embodiments. For example,an established impedance-to-sensitivity relationship can be used todetermine a sensitivity value of the sensor under test, and thesensitivity value can then be used to modify or form a conversionfunction used to convert a sensor signal of the sensor under test intoone or more estimated glucose concentration values. In addition, insteadof calculating an impedance based on the stimulus signal response, oneor more properties of the stimulus signal response (e.g., peak currentvalue, counts, etc.) can be directly correlated to a sensitivity basedon a predetermined relationship between the stimulus signal property andthe sensitivity.

Some embodiments use one or more impedance values of the sensor to form,modify or select a sensitivity profile, also referred to as asensitivity drift curve, of an analyte sensor. A sensor can have asensitivity profile that indicates the sensor's change in sensitivityover time. Although sensors made in substantially the same way undersubstantially the same conditions can exhibit similar sensitivityprofiles, the profiles can still vary. For example, the environment inwhich a particular sensor is used can cause the sensor's sensitivityprofile to differ from other, similar sensors. Accordingly, someembodiments can, for example, select a sensitivity profile out of aplurality of predetermined sensitivity profiles based on a correlationof the calculated one or more impedance values to the selectedsensitivity profile. Further, some embodiments modify a sensorsensitivity profile already associated with the analyte sensor undertest to more closely predict the sensor's sensitivity profile, where themodification is based on the one or more impedance values.

FIG. 17 is a flowchart illustrating a process 1700 for determining apredicted sensitivity profile using one or more sensor membraneimpedance values, in accordance with the present embodiments. At step1702, a stimulus signal is applied to an analyte sensor under test and aresponse is measured at step 1704. Next, one or more sensor membraneimpedance values are calculated based on the response at step 1706.Various techniques for calculating sensor membrane impedance valuesbased on the response that can be used in process 1700 are describedelsewhere herein, such as one or more of the techniques discussed withreference to FIGS. 10-13. A sensitivity profile is then determined basedon the one or more calculated impedance values in step 1708. Process1700 then calculates (which can include retrospectively correctingand/or prospectively calculating) estimated analyte concentration valuesusing the determined sensitivity profile. The estimated analyteconcentration values can then be used for further processing andoutputting, such as displaying information representative of theestimated values on a user device and/or outputting the information toan external computing device.

Further to step 1708, various techniques can be used to determine thesensitivity profile. One technique compares the one or more calculatedimpedance values to a plurality of different predicted sensitivityprofiles and selects a predicted sensitivity profile that best fits theone or more calculated impedance values. The plurality of differentpredicted sensitivity profiles can be stored in memory of the sensorelectronics, for example. Another technique includes using an estimativealgorithm to predict or determine a sensitivity profile based on the oneor more calculated impedance values. A further technique includesdetermining a sensitivity profile by modifying a sensitivity profileassociated with the sensor under test. Modifying the sensitivity profilecan include using an estimative algorithm to modify the sensitivityprofile to more closely track the sensitivity profile of the sensorunder test based on the one or more calculated impedance values.

Some embodiments compare one or more impedance values of an analytesensor under test to a predetermined or predicted sensitivity profileassociated with the sensor to determine if the sensor is functioningproperly. A sensor can be predicted to have a particular sensitivityprofile based on, for example, a study of sensitivity changes over timeof sensors made in substantially the same way and used undersubstantially the same conditions. However, it can be determined that asensor is functioning improperly—due to, for example, improper sensorinsertion, damage to the sensor during shipping, manufacturing defectsand the like—if the sensor is found not to be sufficiently tracking itspredicted sensitivity profile based on sensitivities derived fromimpedance measurements of the sensor. Put another way, it can bedetermined that a sensor is not functioning properly if one or moreimpedance values of a sensor's membrane do not sufficiently correspondto a predicted sensitivity profile of the sensor, for example, becausethe impedance of a sensor membrane can indicate a sensitivity of thesensor.

FIG. 18 is a flowchart illustrating a process 1800 for determiningwhether an analyte sensor under test is functioning properly based on apredicted sensitivity profile (curve) and one or more impedancemeasurements, in accordance with the present embodiments. At step 1802,a stimulus signal is applied to an analyte sensor under test and aresponse is measured at step 1804. Next, one or more sensor membraneimpedance values are calculated based on the signal response at step1806. Various stimulus signals and techniques for calculating sensormembrane impedance values based on the signal response that can be usedin the process 1800 are described elsewhere herein, such as any one ofthe techniques discussed with reference to FIGS. 10-13. The process 1800then determines a correspondence of the one or more calculated impedancevalues to a sensitivity profile in step 1808. Next, in decision step1810, the process 1800 queries whether the one or more calculatedimpedance values sufficiently correspond to the predicted sensitivityprofile. If it is determined that the one or more calculated impedancevalues sufficiently correspond to the predicted sensitivity profile,then the process 1800 confirms proper operation of the analyte sensorunder test. If confirmed to be proper in step 1810, the process 1800 maythen be repeated after a predetermined time delay ranging from about 1minute to 1 day, for example about 10 minutes, 1 hour, 12 hours, or 1day. However, the process 1800 initiates an error routine 1812 if it isdetermined that the one or more calculated impedance values do notsufficiently correspond to the predicted sensitivity profile. Errorroutine 1812 can include triggering an audible alarm, displaying anerror message on a user display, discontinuing display of sensor data ona user display, sending a message to a remote communication device overa communication network, such as a mobile phone over a cellular networkor remote computer over the internet, and the like. The error routinecan also include modifying the predicted sensitivity profile—based onthe one or more impedance measurements, for example—or selecting a newpredicted sensitivity profile based on the one or more impedancemeasurements. The modified predicted sensitivity profile or newpredicted sensitivity profile can be a sensitivity profile that moreclosely corresponds to changes in sensitivity of the sensor under testbased on the one or more impedance measurements as compared to theunmodified or previously used predicted sensitivity profile.

Further to step 1808 of the process 1800, various statistical analysistechniques can be used to determine a correspondence of the one or moreimpedance values to the predicted sensitivity profile. For example,correspondence can be determined based on whether a sensitivity valuederived from the calculated impedance value (e.g., derived from apredetermined relationship of impedance and sensitivity) differs by noless than a predetermined threshold amount from a predicted sensitivityvalue as determined from the predicted sensitivity profile. Thepredetermined threshold amount can be in terms of an absolute value or apercentage. As another example, correspondence can be determined basedon a data association function. The term “data association function,” asused herein, is used in its ordinary sense, including, withoutlimitation, a statistical analysis of data and particularly itscorrelation to, or deviation from, a particular curve. A dataassociation function can be used to show data association. For example,sensor sensitivity data derived from impedance measurements describedherein may be analyzed mathematically to determine its correlation to,or deviation from, a curve (e.g., line or set of lines) that defines asensor sensitivity profile. This correlation or deviation is the dataassociation. A data association function can also be used to determinedata association. Examples of data association functions include, butare not limited to, linear regression, non-linear mapping/regression,rank (e.g., non-parametric) correlation, least mean square fit, meanabsolute deviation (MAD), mean absolute relative difference. In one suchexample, the correlation coefficient of linear regression is indicativeof the amount of data association of sensitivity data derived fromimpedance measurements from a sensitivity profile, and thus the qualityof the data and/or sensitivity profile. Of course, other statisticalanalysis methods that determine a correlation of one or more points to acurve can be used in the process 1800 in addition to those describedherein.

The processes 1700, 1800 can use one or more impedance values. When morethan one impedance value is used, each impedance value can betime-spaced from the other impedance value(s). In other words, oneimpedance value can be taken at a first point in time t₁ (indicative ofa sensor impedance at time t₁), a second impedance value can be taken ata second, later point in time t₂ (indicative of a sensor impedance attime t₂), and third impedance value taken at a third, even later pointin time t₃ (indicative of a sensor impedance at time t₃), and so on.Further, the time between t₁ and t₂ can be a first amount of time andthe time between t₂ and t₃ can be a second amount of time that is eitherthe same as or different from the first amount of time. The time-spacedimpedance values can then be used separately or combined using astatistical algorithm (e.g., calculating an average or median value ofthe time-spaced values). The separate values or combined value can thenbe used to determine a sensitivity value and/or sensitivity profile instep 1708 of the process 1700 or determine a correspondence with asensitivity profile in step 1808 of the process 1800, for example.Additionally or alternatively, one or more of the impedance values canbe taken at substantially the same time, but each derived using adifferent measurement technique, such as any of the measurementtechniques described herein. For example, a first impedance can becalculated using a step voltage technique as described in the process ofFIG. 12, and a second impedance can be calculated using a sine waveoverlay technique as described in the process of FIG. 10. The impedancevalues derived from different measurement techniques can then be appliedto a statistical algorithm (e.g., calculating an average or medianvalue) to determine a processed impedance value. The processed impedancevalue can then be used to determine a sensitivity value and/orsensitivity profile in step 1708 of the process 1700 or determine acorrespondence with a sensitivity profile in step 1808 of the process1800, for example.

Temperature

Some embodiments can use signal processing techniques to determine atemperature of the sensor. For example, a stimulus signal can be appliedto a sensor and a signal response measured and, based on the signalresponse, a temperature of the sensor can be derived.

An impedance of a sensor membrane, as determined using one of thetechniques described with reference to FIGS. 10-13, for example, can beused to estimate a temperature of the sensor in accordance with thepresent embodiments. Although not wishing to be bound by theory, it isbelieved that sensitivity of a sensor is affected by temperature, wherea higher temperature can result in a higher sensitivity and a lowertemperature can result in a lower sensitivity. Similarly, because animpedance of a sensor membrane can have a direct relationship to thesensor's sensitivity, it is believed that a higher temperature canresult in lower impedance and a lower temperature can result in a higherimpedance. That is, sensitivity and impedance can have a directrelationship to the sensor's temperature. Accordingly, using a knownrelationship between impedance and temperature—based on previouslyconducted studies of substantially similar sensors, for example—one canestimate a sensor's temperature based on a sensor impedance measurement.

In some embodiments, a temperature sensor may be provided on or in thesensor 102 at a working electrode of the sensor so that the temperaturesensor is placed subcutaneously in a host along with the sensor 102.Other implementations may use electrochemistry techniques, such asElectrochemical Impedance Spectroscopy (EIS), to measure the temperatureat the working electrode.

In some embodiments, a temperature sensor may be placed in the sensorassembly 100 at a location that is on or near the host's skin surface.The temperature sensor may be integral with the sensor assembly 100,such that it is disposed of, along with the sensor 102 and the sensorassembly 100, at the end of the life of the sensor 102. The temperaturesensor may be in direct contact with the skin, or be coated or potted ina material that has good thermal conductivity. The material may includean adhesive pad. In addition, the temperature sensor (or thermalconductive material) may be surrounded with a thermally insulatingmaterial to prevent external temperature changes from impacting thetemperature sensing. The temperature sensor may be designed into thesensor assembly 100 to reduce or eliminate any air gap between the skinand the thermal conductive material or temperature sensor.

In some embodiments, the temperature sensor is an integral component ofthe sensor electronics 104. To measure as close as possible to thetemperature at the working electrode, several implementations may beused, as discussed below.

In some embodiments, a temperature sensor may be provided on anunderside of an adhesive pad or base of the sensor assembly 100 in theform of a screen printed thick film material that changes resistance asa function of temperature. For example, the material may be printed inthe form of a meandering path. By measuring the electric resistance ofthis meander, the skin temperature may be estimated. An example ofsuitable material that has a high temperature-dependent resistance issemiconductors like doped silicon. A screen printable ink based on smallparticles (e.g., 1-20 μm) may be formulated.

FIG. 19 is a flowchart illustrating a process 1900 for determining asensor temperature, in accordance with the present embodiments. At step1902, a stimulus signal is applied to an analyte sensor under test, anda response is measured and recorded at step 1904. Impedance iscalculated based on the signal response at step 1906. The impedance canbe calculated using, for example, any of the techniques described hereinsuch as those described with reference to FIGS. 10-13. A temperature ofthe sensor is then estimated based on a predetermined relationshipbetween impedance and temperature at step 1908. The temperature can thenbe used to estimate analyte concentration values (e.g., glucoseconcentration) using sensor data. For example, the temperature can beused to compensate for temperature effects on sensor sensitivity and,based on the sensitivity compensation, more accurate analyteconcentration values can be estimated.

A relationship between sensor sensitivity and different temperatures canbe mathematically modeled (e.g., by fitting a mathematical curve to datausing one of the modeling techniques used herein), and the mathematicalmodel can then be used to compensate for temperature effects on thesensor sensitivity. That is, a sensitivity of a sensor (which isaffected by the sensor's temperature) can be determined based onassociating a measured impedance of the sensor to the mathematicalcurve. The predetermined relationship between impedance and temperaturecan be determined by studying impedances of similar sensors over a rangeof temperatures. Sensor data can then be converted to estimated analyteconcentration values based on the determined sensor sensitivity.

As a non-limiting example, some embodiments of analyte sensors can havean essentially linear relationship of impedance to temperature after asensor run-in period. The slope of the linear relationship can beestablished by studying sensors made in substantially the same way asthe sensor under test over a range of temperatures. Thus, a sensortemperature can be estimated by measuring an impedance value of thesensor's membrane and applying the impedance value to the establishedlinear relationship.

Some embodiments can compare a first sensor temperature, where the firsttemperature is derived from an impedance measurement of an analytesensor, with a second sensor temperature, where the second sensortemperature can be derived independent from the impedance measurement.The second estimated temperature can be measured using a thermistor, forexample. The thermistor can be configured to measure an in vivo or exvivo temperature, and can be located on the analyte sensor or separatefrom the analyte sensor. As non-limiting examples, the thermistor can beintegral with the analyte sensor, positioned on the surface of the skinof a host adjacent to an insertion site in which the analyte sensor isimplanted, positioned on the skin of the host at a location away fromthe insertion site or spaced apart from the host entirely, such as on ahandheld device carried by the host. Factors contributing to a change insensor sensitivity or a change in other sensor properties can then bedetermined or confirmed based, at least in part, on the comparison ofthe first and second temperatures.

In certain embodiments, the system may prompt the user to input one ormore reference BG values in response to a measured sensitivity change.For example, where a measured sensitivity change is high, such as at orabove a threshold value, the system may prompt the user for one or moreBG values. If the BG values do not correlate with the measuredsensitivity change, the sensor may be malfunctioning and may need to bereplaced.

In some embodiments, host-specific measured values can be stored andused later for various purposes. For example, these values can be usedas seed values, for validating later-taken measurements, forpersonalized drift compensation, etc. Example values that can be storedand used later include sensitivity (m), baseline (b), change insensitivity (Δm), change in baseline (Δb), sensitivity at implant(m_(implant)), baseline at implant (b_(implant)), sensitivity atend-of-life (m_(end-of-life)), baseline at end-of-life(b_(end-of-life)), drift profile (e.g., sensitivity drift curve and/orbaseline drift curve), etc.

Determining a Drift Compensation Function (Sensitivity or BaselineShift) to be Applied

In the present embodiments, a variety of different drift compensationfunctions may be applied after the change in sensitivity and/or baselinehas been measured. One example of a drift compensation function is astepwise function, which may be a linear piece-wise function. The linearpiece-wise function is described with reference to FIGS. 20 and 21. FIG.20 represents an ideal compensation curve C to be applied to a givendrift curve. It is ideal in the sense that it is a mirror image of thedrift curve, so that if the compensation curve and the drift curve weresuperimposed they would resolve to a straight, horizontal line, as inFIG. 6. A variety of methodologies may be employed, as is appreciated bya skilled artisan, to obtain drift curves and compensation functions. Inone example, data from subjects without diabetes was assumed to have anaverage constant at approximately 100 mg/dL, the raw sensor signal wasplotted as a function of time, and the function that best representedthe data was determined using commercially-available software (e.g.,TableCurve), after which the mathematical inverse was applied to the rawsensor signal, thereby de-convolving (removing) the drift. In anotherexample, data from subjects with diabetes was filtered to isolate a bandof the raw signal associated with a narrow range of glucose (e.g.,80-120 mg/dL), after which the methodology from the previous example wasapplied.

FIG. 20 illustrates a smooth curve C in the region spanning the firstday or two after the sensor is implanted. This is the curve thatrepresents how to compensate for sensor drift at periodic intervals,such as every one, two, five, ten or fifteen minutes. But, for practicalreasons, the sensor is recalibrated at longer intervals, such as, forexample, every six hours. Thus, with reference to FIG. 21, the linearpiece-wise function breaks the ideal curve C into a plurality ofdiscrete line segments S, where a length of each segment S correspondsto the interval between recalibrations. The slope at the center of thecurve C within each segment S is used as the drift compensation functionfor that interval. At the end of each interval, another recalibrationoccurs and the applied drift compensation function is adjusted asnecessary.

In some embodiments, a family of transform functions may be applied tothe sensor data, where the family of transform functions represents afamily of curves or compensation functions spanning a range ofacceptability. Then, one of the transform functions may be selected fromthe family. For example, the transform function that causes theconversion function to be most linear or most accurate with respect toobserved drift may be selected, similar to the example shown in FIG. 6,wherein the selected compensation function is one that effectively nullsthe sensors drift. In another example, multiple compensation functionsare applied to the calibrations set and the function that results in thebest model between reference glucose value and drift-compensated sensorvalue is selected. For example, it is believed that changes in impedancetrack changes in sensitivity. Thus, changes in impedance can be mappedon a curve, and that curve may line up most closely with one of thetransform functions. The more data gathered, the more it informs whichtransform function to select. Further, with hindsight information, itmay be determined that a current conversion function is not the bestconversion function, so another conversion function in the set may beselected instead. The family of transform functions may, for example,include a “do nothing” family member that may be applied if it isdetermined that the sensor has been restarted.

In some embodiments, an applied drift compensation function comprises amathematical inverse of the equation that defines the curve traced bythe drift. For example, experimental results have shown that for thesubject population using certain example continuous glucose sensors, thedrift follows a simple second-order polynomial (quadratic) equation ofthe formy=a+bx+cx ².

Thus, a simple transform function for the above drift equation isdefined as

${T = {\frac{1}{y} = \frac{1}{a + {bx} + {cx}^{2}}}},$which is the mathematical inverse of the drift equation. Application ofthe mathematical inverse of the drift equation removes thetime-dependent drift, or upward trend, in the data, because the curvesdefined by the drift equation and the transform function, whensuperimposed, resolve to a straight horizontal line.

In some embodiments, an applied drift compensation function comprises anextended Kalman filter. The Kalman filter is an algorithm that yields anoptimized estimate of a system's state. The algorithm works recursivelyin real time on streams of noisy input observational data, such assensor measurements, and filters out errors using a least-squarescurve-fit optimized with a mathematical prediction of the future stategenerated through a modeling of the system's physical characteristics.The model estimate is compared to the observation and this difference isscaled by a factor known as the Kalman gain, which is then fed back asan input into the model for the purpose of improving subsequentpredictions. The gain can be “tuned” for improved performance. With ahigh gain, the filter follows the observations more closely. With a lowgain, the filter follows the model predictions more closely. This methodproduces estimates that tend to be closer to the true unknown valuesthan those that would be based on a single measurement alone or themodel predictions alone.

With the Kalman filter, sensors provide measurements as inputs to thesystem. But such measurements are intermittent, sometimes withsignificant intervals between measurements. Also, the measurements maybe corrupted with a certain amount of error, including noise. The Kalmanfilter algorithm is an optimized method for determining the bestestimation of the system's state. The basic concept is similar to simplemathematical curve-fitting of data points using a least-squaresapproximation (where the deviation is squared so that negative errorswill not cancel out positive ones) and enables predictions of the stateinto future time steps. The most basic concepts of the filter arerelated to interpolation and extrapolation, where data estimates arefilled in between given points and the latter involves data estimatesbeing extended beyond the given set (as with future estimates). In eachtime step, the Kalman filter produces estimates of the true unknownvalues, along with their uncertainties. Once the outcome of the nextmeasurement is observed, these estimates are updated using a weightedaverage, with more weight being given to estimates with loweruncertainty.

The extended Kalman filter is the nonlinear version of the Kalman filterwhich linearizes about an estimate of the current mean and covariance.In the extended Kalman filter, the state transition and observationmodels need not be linear functions of the state but may instead bedifferentiable functions:x _(k)=ƒ(x _(k-1) ,u _(k-1))+w _(k-1)z _(k) =h(x _(k))+v _(k)Where w_(k) and v_(k) are the process and observation noises which areboth assumed to be zero mean multivariate Gaussian noises withcovariance Q_(k) and R_(k) respectively.

The function ƒ can be used to compute the predicted state from theprevious estimate and similarly the function h can be used to computethe predicted measurement from the predicted state. However, ƒ and hcannot be applied to the covariance directly. Instead a matrix ofpartial derivatives (the Jacobian) is computed. At each timestep theJacobian is evaluated with current predicted states. These matrices canbe used in the Kalman filter equations. This process essentiallylinearizes the non-linear function around the current estimate.

Extended Kalman filters have been proposed for continuous glucosemonitoring. One difference in the present extended Kalman filter model,described below, is the sensitivity drift model. This model takes intoaccount the decaying exponential increase in sensitivity that has beenobserved in experimental data. Using the extended Kalman filter model,sensor sensitivity is continuously updated by addition with a driftparameter, where the drift parameter is modeled as an exponentiallycorrelated random variable. The drift parameter could also be modeled asa random ramp plus a random constant plus a random walk. Forcomputational efficiency, EKF implementations, such as Fast KalmanFiltering or Variational Kalman Filtering, may be employed.

The equations below illustrate the present model.

Process

Random walk of rate of change (slope) of IG, where “ω1” is unknown,estimated during burn-in.

${{IG}( {k + 1} )} = {{{IG}(k)} + {{slope}(k)} + {\begin{bmatrix}1 & 0 \\0 & 1\end{bmatrix}\begin{bmatrix}0 \\\omega_{1}\end{bmatrix}}}$Sensitivity

IG is interstitial glucose, m is sensitivity, α is sensitivity drift,ω_(α) is random noise affecting sensitivity drift (estimated),exponentially correlated random drift model (initialization andmultiplier is estimated from group drift model).m(k+1)=m(k)+α(k)α(k+1)=0.998α(k)+ω_(α)Baseline

b is baseline, ω_(β) is random noise affecting baseline (estimated).b(k+1)=b(k)+ω_(β)Measurements

SMBG: φ(k) is flag set to 1 when SMBG collected, v₁ can be guessed. Notethis version is ignoring IG-BG kineticsSMBG=ϕ(k)IG(k)+v ₁(k)

Sensor Counts (SC): v₂ is measurement noise, ˜ is not or inverse.Performed whenever SMBG is not collectedSC=˜ϕ(k)[m(k)IG(k)+b(k)+v ₂(k)]Setup

Parameter vector x and measurement vector y:

$\begin{bmatrix}{IG} \\{slope} \\m \\b \\\alpha\end{bmatrix} = {{\begin{bmatrix}x_{1} \\x_{2} \\x_{3} \\x_{4} \\x_{5}\end{bmatrix}\begin{bmatrix}{SC} \\{SMBG} \\m \\b\end{bmatrix}} = \begin{bmatrix}y_{1} \\y_{2} \\y_{3} \\y_{4}\end{bmatrix}}$State-Space Dynamic Model

${x( {k + 1} )} = {{f( {{x(k)},{\omega(k)}} )} = \begin{matrix}{{x_{1}(k)} + {x_{2}(k)}} \\{{x_{2}(k)} + {\omega_{1}(k)}} \\{{x_{3}(k)} + {x_{5}(k)}} \\{{x_{4}(k)} + {\omega_{b}(k)}} \\{{0.998\mspace{11mu}{x_{5}(k)}} + {\omega_{\alpha}(k)}}\end{matrix}}$Measurement Model

${y(k)} = {{h( {{x(k)},{v(k)}} )} = \begin{bmatrix}{\sim{{\phi(k)}\lbrack {{{x_{1}(k)}{x_{3}(k)}} + {x_{4}(k)} + {v_{1}(k)}} \rbrack}} \\{{\phi(k)}\lbrack {{x_{1}(k)} + {v_{2}(k)}} \rbrack} \\{{\phi(k)}\lbrack {{x_{3}(k)} + {v_{3}(k)}} \rbrack} \\{{\phi(k)}\lbrack {{x_{5}(k)} + {v_{5}(k)}} \rbrack}\end{bmatrix}}$

Note that these models are nonlinear. Therefore, the extended Kalmanfilter is required.

EKF Implementation

Estimation of state vector and covariance matrix:{circumflex over (x)}(k+1|k)=ƒ({circumflex over (x)}(k|k),0)P(k+1|k)=A _(k) P(k|k)A _(k) ^(T) +W _(k) Q _(k) W _(k) ^(T)Measurement UpdateK _(k) =P(k+1|k)H _(k) ^(T)(H _(k) P(k+1|k)H _(k) ^(T) +V _(k) R _(k) V_(k) ^(T))⁻¹{circumflex over (x)}(k+1|k+1)={circumflex over (x)}(k+1|k)+K_(k)(y(k+1)−h({circumflex over (x)}(k+1|k),0))P(k+1|k+1)=(I−K _(k) H _(k))P(k+1|k)

Where A_(k) and H_(k) are the Jacobian matrices of the partialderivatives of ƒ and h with respect to x.

$A_{k} = \begin{bmatrix}1 & 1 & 0 & 0 & 0 \\0 & 1 & 0 & 0 & 0 \\0 & 0 & 1 & 0 & 1 \\0 & 0 & 0 & 1 & 0 \\0 & 0 & 0 & 0 & 0.98\end{bmatrix}$

Note that H_(k) changes every time (greater correction for higher IG andm).

W_(k) = I(5, 5) V_(k) = I(3, 3)  or  1 ${Q(k)} = \begin{bmatrix}{2\text{,}000} & \; & \; & \; & \; \\\; & {4\text{,}000\text{,}000} & \; & \; & \; \\\; & \; & 20 & \; & \; \\\; & \; & \; & 20 & \; \\\; & \; & \; & \; & 20\end{bmatrix}$ ${R(k)} = {\begin{bmatrix}4 & \; & \; \\\; & 16 & \; \\\; & \; & 16\end{bmatrix}\mspace{14mu}{or}\mspace{14mu} 4}$Prediction

Predict 5 minutes ahead to deal with filter time delay (possibly BG-IGkinetics):x=A*x;P=A*P*A′+Q;

In some embodiments, the calculated drift rate (e.g., measured orsmoothed drift rate based on a BG value described in more detailelsewhere herein) at a specific point in time (e.g. t0) is used tocontinuously (e.g., iteratively) adjust the sensor data for drift aftert0 until the next drift rate calculation. In these embodiments, theadjustment value applied to each sensor data value is based on thecalculated drift rate and the elapsed time since the calibration wastaken. For example, by determining the time (e.g., 5, 10, 15, 20, 25, 30minutes and so on) since t0 and multiplying by the calculated drift rate(e.g., 0.5% per hour), the result is an adjustment value (or scalingfactor) that is applied to adjust the sensor data (e.g., raw signal orEGV) at that time (e.g., 5, 10, 15, 20, 25, 30 minutes and so on).Accordingly, the further the current time is from t0, the moreadjustment is applied. In some embodiments, the adjustment value mayplateau (i.e., remain at the same adjustment value) at a fixed timepoint after t0 (e.g., 10 hours) until a new calibration occurs. In theseembodiments, variables that may be adjusted within the driftcompensation function include drift envelope drift rates (e.g. the maxcorrection rate that can be applied in a given time window), start timeof compensation (e.g. the time after sensor insertion that the driftcompensation function starts), end time of the drift compensationfunction, start time of the different time windows in the driftenvelope, length of time windows (steps in a stepwise function), or thelike, which may be adaptive based on a seed value, a measured driftrate, reliability information, or the like.

In some embodiments, boundaries may be applied to the drift compensationfunction in order to ensure that the applied drift compensation functionis appropriate for the measured drift rate. These boundaries may bebased on a priori knowledge. For example, for a given drift rate, anapplied compensation function may have a rate of compensation that fallswithin a certain range. If the rate of compensation is outside thatrange, an appropriate adjustment may be made. Further, the appliedboundaries could be adaptive over time. For example, as the drift rateof the sensor decreases, confidence in the accuracy of data output fromthe sensor increases. Thus, narrower boundaries may be applied asconfidence in the sensor increases.

In other embodiments, boundaries may be applied to detect errors insensor readings and/or reference analyte readings. Where such errors aredetected, the system may be configured to not report those values to theuser. This aspect would have the advantageous effect of bolstering theuser's confidence in the accuracy of the monitoring system, therebymaking it more likely that the user would use the monitoring system. Asdiscussed above, the applied boundaries could be adaptive over time.

In some embodiments, multiple drift compensation techniques may beapplied in parallel. For example, a first drift estimate may be madebased on impedance of the sensor, and a second drift estimate may bemade based on a BG value. A predetermined correlation may then berequired between the first and second drift estimates. If thepredetermined correlation is not met, the two measurements may then berepeated as many times as necessary until the predetermined correlationis met.

In some embodiments, an appropriate drift compensation function may beinferred from an absolute sensitivity of the sensor. It has beenobserved that sensor sensitivity usually levels off at roughly the sameplace. Thus, a higher sensitivity at implant indicates that a moregradual sensitivity drift profile should be used and vice versa.

As discussed above, host-specific measured values can be stored and usedlater for various purposes. Another example of how these values can beused includes determining the drift profile/drift compensation function.Example values that can be stored and used later include sensitivity(m), baseline (b), change in sensitivity (Δm), change in baseline (Δb),sensitivity at implant (m_(implant)), baseline at implant (b_(implant)),sensitivity at end-of-life (m_(end-of-life)), baseline at end-of-life(b_(end-of-life)), drift profile, etc.

Applying Drift Compensation Function to Sensor Values Until NextMeasurement of Sensitivity Change

Once the appropriate drift compensation function to be applied isdetermined, it is applied to the sensor data. The drift compensationfunction may be applied to, for example, the raw sensor signal orconverted (calibrated) signals. The drift compensation function may beapplied pre-processing or post-processing. In pre-processing, the driftcompensation function is applied to the sensor data in real time. Inpost-processing, the drift compensation function is applied to thesensor data retrospectively.

In some embodiments, the drift compensation function may be applied toall data output by the sensor. In other embodiments, the driftcompensation function may not be applied to some of the data output bythe sensor. For example, the drift compensation function may ignoreoutlying data points, or may be applied to every other data point, everythird data point, etc. In still other embodiments, the driftcompensation function may be applied at set time intervals, such asevery two hours, every hour, every half-hour, every fifteen minutes,etc.

Certain embodiments may include an automatic stop function for the driftcompensation function. For example, it has been observed that driftlargely disappears after a certain amount of time has elapsed sinceimplantation of the sensor. Thus, the system may be configured to stopapplying drift compensation after the sensor has been implanted for acertain number of hours or days, such as three days for example. In analternative embodiment, the system may be configured to stop applyingdrift compensation when the measured sensitivity change falls below acertain threshold. For example, the threshold may be less than a 5%change, less than a 4% change, less than a 3% change, less than a 2%change, less than a 1% change, etc.

Other Algorithmic Responses to Measured Drift Change

In addition to the above embodiments, a variety of other algorithmicresponses may be applied to a measured drift change. For example, aweighting of matched data pairs may be dynamically adjusted in responseto drift. When the drift rate is high, older matched data pairs may begiven less weight. This technique focuses the applied drift compensationon more recent matched data pairs, which are closer in magnitude to thereal-time drift rate. The resulting applied drift compensation thus moreclosely matches the real-time drift rate. As the rate of driftdecreases, the weight given to older data pairs may rise. Additionallyor alternatively, subsequent to the determination of the drift rate,sensor values of the matched data pairs may be retrospectively adjustedwithin each matched data pair by adjusting the sensor value according tothe determined amount of drift at the time corresponding to the matchingof the data pair. Advantageously, the retrospective adjustment ofmatched data pairs provides for drift-corrected sensor readings that aremore consistent with the calibration model used for a stable sensor. Forexample, if the calibration model is a first-order polynomial thenmatched pairs (reference glucose and sensor counts) are expected to lieon a line. The presence of sensor drift degrades this relationship witha time-dependent error that, for example, can cause the oldest matchedpairs to be below the best-fit line and the newest matched pairs to beabove the line. When a useful drift correction is applied to the matchedpairs it results an improved agreement between the matched pairsagreement and the model. This agreement may be quantified with standardregression metrics that assess fit quality such as correlationcoefficient, sum of squared errors, or uncertainty of the resultingslope and baseline, which quantified agreement may be used in furtherprocessing of the sensor data. While many of the examples described hereapply a correction to the glucose values based on the sensor signalthese techniques can be applied to correct the reference values as afunction of time to produce equivalent results.

In some embodiments, if a measured drift rate is greater than athreshold value, a calibration function may be restarted. For example,if the measured drift rate is greater than the high end of this range bya predetermined amount, or percentage, such as 1%, 2%, 3%, 4%, 5%, 10%,15%, 20%, 30%, 40%, 50%, 60%, 70%, 80%, 90%, or 100%, it is likely to beerroneous, and the calibration function may be restarted.

In some embodiments, the conversion function may change over time as thedrift rate changes. For example, the conversion function may considerall matched data pairs in a given window of time, where the length ofthat time may vary. During a period of severe drift, the window of timemay be shorter, whereas when drift levels off the window of time maylengthen. Alternatively, the number of matched pairs in the calibrationset may change over time. During a period of severe drift, fewer andmore recent data pairs may be considered, whereas when drift levels offmore data pairs may be considered.

In some embodiments, if the sensor is exhibiting characteristics, suchas drift, that are extreme and not within expected boundaries based on apriori knowledge, a process may be restarted. For example, an appliedcompensation algorithm may be restarted, or the sensor may be restarted.

Methods and devices that are suitable for use in conjunction withaspects of the preferred embodiments are disclosed in U.S. Pat. Nos.4,757,022; 4,994,167; 6,001,067; 6,558,321; 6,702,857; 6,741,877;6,862,465; 6,931,327; 7,074,307; 7,081,195; 7,108,778; 7,110,803;7,134,999; 7,136,689; 7,192,450; 7,226,978; 7,276,029; 7,310,544;7,364,592; 7,366,556; 7,379,765; 7,424,318; 7,460,898; 7,467,003;7,471,972; 7,494,465; 7,497,827; 7,519,408; 7,583,990; 7,591,801;7,599,726; 7,613,491; 7,615,007; 7,632,228; 7,637,868; 7,640,048;7,651,596; 7,654,956; 7,657,297; 7,711,402; 7,713,574; 7,715,893;7,761,130; 7,771,352; 7,774,145; 7,775,975; 7,778,680; 7,783,333;7,792,562; 7,797,028; 7,826,981; 7,828,728; 7,831,287; 7,835,777;7,857,760; 7,860,545; 7,875,293; 7,881,763; 7,885,697; 7,896,809;7,899,511; 7,901,354; 7,905,833; 7,914,450; 7,917,186; 7,920,906;7,925,321; 7,927,274; 7,933,639; 7,935,057; 7,946,984; 7,949,381;7,955,261; 7,959,569; 7,970,448; 7,974,672; 7,976,492; 7,979,104;7,986,986; 7,998,071; 8,000,901; 8,005,524; 8,005,525; 8,010,174;8,027,708; 8,050,731; 8,052,601; 8,053,018; 8,060,173; 8,060,174;8,064,977; 8,073,519; 8,073,520; 8,118,877; 8,128,562; 8,133,178;8,150,488; 8,155,723; 8,160,669; 8,160,671; 8,167,801; 8,170,803;8,195,265; 8,206,297; 8,216,139; 8,229,534; 8,229,535; 8,229,536;8,231,531; 8,233,958; 8,233,959; 8,249,684; 8,251,906; 8,255,030;8,255,032; 8,255,033; 8,257,259; 8,260,393; 8,265,725; 8,275,437;8,275,438; 8,277,713; 8,280,475; 8,282,549; 8,282,550; 8,285,354;8,287,453; 8,290,559; 8,290,560; 8,290,561; 8,290,562; 8,292,810;8,298,142; 8,311,749; 8,313,434; 8,321,149; 8,332,008; 8,346,338;8,364,229; 8,369,919; 8,374,667; 8,386,004; and 8,394,021.

Methods and devices that are suitable for use in conjunction withaspects of the preferred embodiments are disclosed in U.S. PatentPublication No. 2003-0032874-A1; U.S. Patent Publication No.2005-0033132-A1; U.S. Patent Publication No. 2005-0051427-A1; U.S.Patent Publication No. 2005-0090607-A1; U.S. Patent Publication No.2005-0176136-A1; U.S. Patent Publication No. 2005-0245799-A1; U.S.Patent Publication No. 2006-0015020-A1; U.S. Patent Publication No.2006-0016700-A1; U.S. Patent Publication No. 2006-0020188-A1; U.S.Patent Publication No. 2006-0020190-A1; U.S. Patent Publication No.2006-0020191-A1; U.S. Patent Publication No. 2006-0020192-A1; U.S.Patent Publication No. 2006-0036140-A1; U.S. Patent Publication No.2006-0036143-A1; U.S. Patent Publication No. 2006-0040402-A1; U.S.Patent Publication No. 2006-0068208-A1; U.S. Patent Publication No.2006-0142651-A1; U.S. Patent Publication No. 2006-0155180-A1; U.S.Patent Publication No. 2006-0198864-A1; U.S. Patent Publication No.2006-0200020-A1; U.S. Patent Publication No. 2006-0200022-A1; U.S.Patent Publication No. 2006-0200970-A1; U.S. Patent Publication No.2006-0204536-A1; U.S. Patent Publication No. 2006-0224108-A1; U.S.Patent Publication No. 2006-0235285-A1; U.S. Patent Publication No.2006-0249381-A1; U.S. Patent Publication No. 2006-0252027-A1; U.S.Patent Publication No. 2006-0253012-A1; U.S. Patent Publication No.2006-0257995-A1; U.S. Patent Publication No. 2006-0258761-A1; U.S.Patent Publication No. 2006-0263763-A1; U.S. Patent Publication No.2006-0270922-A1; U.S. Patent Publication No. 2006-0270923-A1; U.S.Patent Publication No. 2007-0027370-A1; U.S. Patent Publication No.2007-0032706-A1; U.S. Patent Publication No. 2007-0032718-A1; U.S.Patent Publication No. 2007-0045902-A1; U.S. Patent Publication No.2007-0059196-A1; U.S. Patent Publication No. 2007-0066873-A1; U.S.Patent Publication No. 2007-0173709-A1; U.S. Patent Publication No.2007-0173710-A1; U.S. Patent Publication No. 2007-0208245-A1; U.S.Patent Publication No. 2007-0208246-A1; U.S. Patent Publication No.2007-0232879-A1; U.S. Patent Publication No. 2008-0045824-A1; U.S.Patent Publication No. 2008-0083617-A1; U.S. Patent Publication No.2008-0086044-A1; U.S. Patent Publication No. 2008-0108942-A1; U.S.Patent Publication No. 2008-0119703-A1; U.S. Patent Publication No.2008-0119704-A1; U.S. Patent Publication No. 2008-0119706-A1; U.S.Patent Publication No. 2008-0183061-A1; U.S. Patent Publication No.2008-0183399-A1; U.S. Patent Publication No. 2008-0188731-A1; U.S.Patent Publication No. 2008-0189051-A1; U.S. Patent Publication No.2008-0194938-A1; U.S. Patent Publication No. 2008-0197024-A1; U.S.Patent Publication No. 2008-0200788-A1; U.S. Patent Publication No.2008-0200789-A1; U.S. Patent Publication No. 2008-0200791-A1; U.S.Patent Publication No. 2008-0214915-A1; U.S. Patent Publication No.2008-0228054-A1; U.S. Patent Publication No. 2008-0242961-A1; U.S.Patent Publication No. 2008-0262469-A1; U.S. Patent Publication No.2008-0275313-A1; U.S. Patent Publication No. 2008-0287765-A1; U.S.Patent Publication No. 2008-0306368-A1; U.S. Patent Publication No.2008-0306434-A1; U.S. Patent Publication No. 2008-0306435-A1; U.S.Patent Publication No. 2008-0306444-A1; U.S. Patent Publication No.2009-0018424-A1; U.S. Patent Publication No. 2009-0030294-A1; U.S.Patent Publication No. 2009-0036758-A1; U.S. Patent Publication No.2009-0036763-A1; U.S. Patent Publication No. 2009-0043181-A1; U.S.Patent Publication No. 2009-0043182-A1; U.S. Patent Publication No.2009-0043525-A1; U.S. Patent Publication No. 2009-0045055-A1; U.S.Patent Publication No. 2009-0062633-A1; U.S. Patent Publication No.2009-0062635-A1; U.S. Patent Publication No. 2009-0076360-A1; U.S.Patent Publication No. 2009-0099436-A1; U.S. Patent Publication No.2009-0124877-A1; U.S. Patent Publication No. 2009-0124879-A1; U.S.Patent Publication No. 2009-0124964-A1; U.S. Patent Publication No.2009-0131769-A1; U.S. Patent Publication No. 2009-0131777-A1; U.S.Patent Publication No. 2009-0137886-A1; U.S. Patent Publication No.2009-0137887-A1; U.S. Patent Publication No. 2009-0143659-A1; U.S.Patent Publication No. 2009-0143660-A1; U.S. Patent Publication No.2009-0156919-A1; U.S. Patent Publication No. 2009-0163790-A1; U.S.Patent Publication No. 2009-0178459-A1; U.S. Patent Publication No.2009-0192366-A1; U.S. Patent Publication No. 2009-0192380-A1; U.S.Patent Publication No. 2009-0192722-A1; U.S. Patent Publication No.2009-0192724-A1; U.S. Patent Publication No. 2009-0192751-A1; U.S.Patent Publication No. 2009-0203981-A1; U.S. Patent Publication No.2009-0216103-A1; U.S. Patent Publication No. 2009-0240120-A1; U.S.Patent Publication No. 2009-0240193-A1; U.S. Patent Publication No.2009-0242399-A1; U.S. Patent Publication No. 2009-0242425-A1; U.S.Patent Publication No. 2009-0247855-A1; U.S. Patent Publication No.2009-0247856-A1; U.S. Patent Publication No. 2009-0287074-A1; U.S.Patent Publication No. 2009-0299155-A1; U.S. Patent Publication No.2009-0299156-A1; U.S. Patent Publication No. 2009-0299162-A1; U.S.Patent Publication No. 2010-0010331-A1; U.S. Patent Publication No.2010-0010332-A1; U.S. Patent Publication No. 2010-0016687-A1; U.S.Patent Publication No. 2010-0016698-A1; U.S. Patent Publication No.2010-0030484-A1; U.S. Patent Publication No. 2010-0036215-A1; U.S.Patent Publication No. 2010-0036225-A1; U.S. Patent Publication No.2010-0041971-A1; U.S. Patent Publication No. 2010-0045465-A1; U.S.Patent Publication No. 2010-0049024-A1; U.S. Patent Publication No.2010-0076283-A1; U.S. Patent Publication No. 2010-0081908-A1; U.S.Patent Publication No. 2010-0081910-A1; U.S. Patent Publication No.2010-0087724-A1; U.S. Patent Publication No. 2010-0096259-A1; U.S.Patent Publication No. 2010-0121169-A1; U.S. Patent Publication No.2010-0161269-A1; U.S. Patent Publication No. 2010-0168540-A1; U.S.Patent Publication No. 2010-0168541-A1; U.S. Patent Publication No.2010-0168542-A1; U.S. Patent Publication No. 2010-0168543-A1; U.S.Patent Publication No. 2010-0168544-A1; U.S. Patent Publication No.2010-0168545-A1; U.S. Patent Publication No. 2010-0168546-A1; U.S.Patent Publication No. 2010-0168657-A1; U.S. Patent Publication No.2010-0174157-A1; U.S. Patent Publication No. 2010-0174158-A1; U.S.Patent Publication No. 2010-0174163-A1; U.S. Patent Publication No.2010-0174164-A1; U.S. Patent Publication No. 2010-0174165-A1; U.S.Patent Publication No. 2010-0174166-A1; U.S. Patent Publication No.2010-0174167-A1; U.S. Patent Publication No. 2010-0179401-A1; U.S.Patent Publication No. 2010-0179402-A1; U.S. Patent Publication No.2010-0179404-A1; U.S. Patent Publication No. 2010-0179408-A1; U.S.Patent Publication No. 2010-0179409-A1; U.S. Patent Publication No.2010-0185065-A1; U.S. Patent Publication No. 2010-0185069-A1; U.S.Patent Publication No. 2010-0185070-A1; U.S. Patent Publication No.2010-0185071-A1; U.S. Patent Publication No. 2010-0185075-A1; U.S.Patent Publication No. 2010-0191082-A1; U.S. Patent Publication No.2010-0198035-A1; U.S. Patent Publication No. 2010-0198036-A1; U.S.Patent Publication No. 2010-0212583-A1; U.S. Patent Publication No.2010-0217557-A1; U.S. Patent Publication No. 2010-0223013-A1; U.S.Patent Publication No. 2010-0223022-A1; U.S. Patent Publication No.2010-0223023-A1; U.S. Patent Publication No. 2010-0228109-A1; U.S.Patent Publication No. 2010-0228497-A1; U.S. Patent Publication No.2010-0240975-A1; U.S. Patent Publication No. 2010-0240976 C1; U.S.Patent Publication No. 2010-0261987-A1; U.S. Patent Publication No.2010-0274107-A1; U.S. Patent Publication No. 2010-0280341-A1; U.S.Patent Publication No. 2010-0286496-A1; U.S. Patent Publication No.2010-0298684-A1; U.S. Patent Publication No. 2010-0324403-A1; U.S.Patent Publication No. 2010-0331656-A1; U.S. Patent Publication No.2010-0331657-A1; U.S. Patent Publication No. 2011-0004085-A1; U.S.Patent Publication No. 2011-0009727-A1; U.S. Patent Publication No.2011-0024043-A1; U.S. Patent Publication No. 2011-0024307-A1; U.S.Patent Publication No. 2011-0027127-A1; U.S. Patent Publication No.2011-0027453-A1; U.S. Patent Publication No. 2011-0027458-A1; U.S.Patent Publication No. 2011-0028815-A1; U.S. Patent Publication No.2011-0028816-A1; U.S. Patent Publication No. 2011-0046467-A1; U.S.Patent Publication No. 2011-0077490-A1; U.S. Patent Publication No.2011-0118579-A1; U.S. Patent Publication No. 2011-0124992-A1; U.S.Patent Publication No. 2011-0125410-A1; U.S. Patent Publication No.2011-0130970-A1; U.S. Patent Publication No. 2011-0130971-A1; U.S.Patent Publication No. 2011-0130998-A1; U.S. Patent Publication No.2011-0144465-A1; U.S. Patent Publication No. 2011-0178378-A1; U.S.Patent Publication No. 2011-0190614-A1; U.S. Patent Publication No.2011-0201910-A1; U.S. Patent Publication No. 2011-0201911-A1; U.S.Patent Publication No. 2011-0218414-A1; U.S. Patent Publication No.2011-0231140-A1; U.S. Patent Publication No. 2011-0231141-A1; U.S.Patent Publication No. 2011-0231142-A1; U.S. Patent Publication No.2011-0253533-A1; U.S. Patent Publication No. 2011-0263958-A1; U.S.Patent Publication No. 2011-0270062-A1; U.S. Patent Publication No.2011-0270158-A1; U.S. Patent Publication No. 2011-0275919-A1; U.S.Patent Publication No. 2011-0290645-A1; U.S. Patent Publication No.2011-0313543-A1; U.S. Patent Publication No. 2011-0320130-A1; U.S.Patent Publication No. 2012-0035445-A1; U.S. Patent Publication No.2012-0040101-A1; U.S. Patent Publication No. 2012-0046534-A1; U.S.Patent Publication No. 2012-0078071-A1; U.S. Patent Publication No.2012-0108934-A1; U.S. Patent Publication No. 2012-0130214-A1; U.S.Patent Publication No. 2012-0172691-A1; U.S. Patent Publication No.2012-0179014-A1; U.S. Patent Publication No. 2012-0186581-A1; U.S.Patent Publication No. 2012-0190953-A1; U.S. Patent Publication No.2012-0191063-A1; U.S. Patent Publication No. 2012-0203467-A1; U.S.Patent Publication No. 2012-0209098-A1; U.S. Patent Publication No.2012-0215086-A1; U.S. Patent Publication No. 2012-0215087-A1; U.S.Patent Publication No. 2012-0215201-A1; U.S. Patent Publication No.2012-0215461-A1; U.S. Patent Publication No. 2012-0215462-A1; U.S.Patent Publication No. 2012-0215496-A1; U.S. Patent Publication No.2012-0220979-A1; U.S. Patent Publication No. 2012-0226121-A1; U.S.Patent Publication No. 2012-0228134-A1; U.S. Patent Publication No.2012-0238852-A1; U.S. Patent Publication No. 2012-0245448-A1; U.S.Patent Publication No. 2012-0245855-A1; U.S. Patent Publication No.2012-0255875-A1; U.S. Patent Publication No. 2012-0258748-A1; U.S.Patent Publication No. 2012-0259191-A1; U.S. Patent Publication No.2012-0260323-A1; U.S. Patent Publication No. 2012-0262298-A1; U.S.Patent Publication No. 2012-0265035-A1; U.S. Patent Publication No.2012-0265036-A1; U.S. Patent Publication No. 2012-0265037-A1; U.S.Patent Publication No. 2012-0277562-A1; U.S. Patent Publication No.2012-0277566-A1; U.S. Patent Publication No. 2012-0283541-A1; U.S.Patent Publication No. 2012-0283543-A1; U.S. Patent Publication No.2012-0296311-A1; U.S. Patent Publication No. 2012-0302854-A1; U.S.Patent Publication No. 2012-0302855-A1; U.S. Patent Publication No.2012-0323100-A1; U.S. Patent Publication No. 2013-0012798-A1; U.S.Patent Publication No. 2013-0030273-A1; U.S. Patent Publication No.2013-0035575-A1; U.S. Patent Publication No. 2013-0035865-A1; U.S.Patent Publication No. 2013-0035871-A1; U.S. Patent Publication No.2005-0056552-A1; U.S. Patent Publication No. 2005-0182451-A1; U.S.Patent Publication No. 2013000536650A1; and U.S. Patent Publication No.2013-0053666-A1.

Methods and devices that are suitable for use in conjunction withaspects of the preferred embodiments are disclosed in U.S. applicationSer. No. 09/447,227 filed on Nov. 22, 1999 and entitled “DEVICE ANDMETHOD FOR DETERMINING ANALYTE LEVELS”; U.S. application Ser. No.12/828,967 filed on Jul. 1, 2010 and entitled “HOUSING FOR ANINTRAVASCULAR SENSOR”; U.S. application Ser. No. 13/461,625 filed on May1, 2012 and entitled “DUAL ELECTRODE SYSTEM FOR A CONTINUOUS ANALYTESENSOR”; U.S. application Ser. No. 13/594,602 filed on Aug. 24, 2012 andentitled “POLYMER MEMBRANES FOR CONTINUOUS ANALYTE SENSORS”; U.S.application Ser. No. 13/594,734 filed on Aug. 24, 2012 and entitled“POLYMER MEMBRANES FOR CONTINUOUS ANALYTE SENSORS”; U.S. applicationSer. No. 13/607,162 filed on Sep. 7, 2012 and entitled “SYSTEM ANDMETHODS FOR PROCESSING ANALYTE SENSOR DATA FOR SENSOR CALIBRATION”; U.S.application Ser. No. 13/624,727 filed on Sep. 21, 2012 and entitled“SYSTEMS AND METHODS FOR PROCESSING AND TRANSMITTING SENSOR DATA”; U.S.application Ser. No. 13/624,808 filed on Sep. 21, 2012 and entitled“SYSTEMS AND METHODS FOR PROCESSING AND TRANSMITTING SENSOR DATA”; U.S.application Ser. No. 13/624,812 filed on Sep. 21, 2012 and entitled“SYSTEMS AND METHODS FOR PROCESSING AND TRANSMITTING SENSOR DATA”; U.S.application Ser. No. 13/732,848 filed on Jan. 2, 2013 and entitled“ANALYTE SENSORS HAVING A SIGNAL-TO-NOISE RATIO SUBSTANTIALLY UNAFFECTEDBY NON-CONSTANT NOISE”; U.S. application Ser. No. 13/733,742 filed onJan. 3, 2013 and entitled “END OF LIFE DETECTION FOR ANALYTE SENSORS”;U.S. application Ser. No. 13/733,810 filed on Jan. 3, 2013 and entitled“OUTLIER DETECTION FOR ANALYTE SENSORS”; U.S. application Ser. No.13/742,178 filed on Jan. 15, 2013 and entitled “SYSTEMS AND METHODS FORPROCESSING SENSOR DATA”; U.S. application Ser. No. 13/742,694 filed onJan. 16, 2013 and entitled “SYSTEMS AND METHODS FOR PROVIDING SENSITIVEAND SPECIFIC ALARMS”; U.S. application Ser. No. 13/742,841 filed on Jan.16, 2013 and entitled “SYSTEMS AND METHODS FOR DYNAMICALLY ANDINTELLIGENTLY MONITORING A HOST'S GLYCEMIC CONDITION AFTER AN ALERT ISTRIGGERED”; U.S. application Ser. No. 13/747,746 filed on Jan. 23, 2013and entitled “DEVICES, SYSTEMS, AND METHODS TO COMPENSATE FOR EFFECTS OFTEMPERATURE ON IMPLANTABLE SENSORS”; U.S. application Ser. No.13/779,607 filed on Feb. 27, 2013 and entitled “ZWITTERION SURFACEMODIFICATIONS FOR CONTINUOUS SENSORS”; U.S. application Ser. No.13/780,808 filed on Feb. 28, 2013 and entitled “SENSORS FOR CONTINUOUSANALYTE MONITORING, AND RELATED METHODS”; U.S. application Ser. No.13/784,523 filed on Mar. 4, 2013 and entitled “ANALYTE SENSOR WITHINCREASED REFERENCE CAPACITY”; U.S. application Ser. No. 13/789,371filed on Mar. 7, 2013 and entitled “MULTIPLE ELECTRODE SYSTEM FOR ACONTINUOUS ANALYTE SENSOR, AND RELATED METHODS”; U.S. application Ser.No. 13/789,279 filed on Mar. 7, 2013 and entitled “USE OF SENSORREDUNDANCY TO DETECT SENSOR FAILURES”; U.S. application Ser. No.13/789,339 filed on Mar. 7, 2013 and entitled “DYNAMIC REPORT BUILDING”;U.S. application Ser. No. 13/789,341 filed on Mar. 7, 2013 and entitled“REPORTING MODULES”; and U.S. application Ser. No. 13/790,281 filed onMar. 8, 2013 and entitled “SYSTEMS AND METHODS FOR MANAGING GLYCEMICVARIABILITY”.

The above description presents the best mode contemplated for carryingout the present invention, and of the manner and process of making andusing it, in such full, clear, concise, and exact terms as to enable anyperson skilled in the art to which it pertains to make and use thisinvention. This invention is, however, susceptible to modifications andalternate constructions from that discussed above that are fullyequivalent. Consequently, this invention is not limited to theparticular embodiments disclosed. On the contrary, this invention coversall modifications and alternate constructions coming within the spiritand scope of the invention as generally expressed by the followingclaims, which particularly point out and distinctly claim the subjectmatter of the invention. While the disclosure has been illustrated anddescribed in detail in the drawings and foregoing description, suchillustration and description are to be considered illustrative orexemplary and not restrictive.

All references cited herein are incorporated herein by reference intheir entirety. To the extent publications and patents or patentapplications incorporated by reference contradict the disclosurecontained in the specification, the specification is intended tosupersede and/or take precedence over any such contradictory material.

Unless otherwise defined, all terms (including technical and scientificterms) are to be given their ordinary and customary meaning to a personof ordinary skill in the art, and are not to be limited to a special orcustomized meaning unless expressly so defined herein. It should benoted that the use of particular terminology when describing certainfeatures or aspects of the disclosure should not be taken to imply thatthe terminology is being re-defined herein to be restricted to includeany specific characteristics of the features or aspects of thedisclosure with which that terminology is associated. Terms and phrasesused in this application, and variations thereof, especially in theappended claims, unless otherwise expressly stated, should be construedas open ended as opposed to limiting. As examples of the foregoing, theterm ‘including’ should be read to mean ‘including, without limitation,’‘including but not limited to,’ or the like; the term ‘comprising’ asused herein is synonymous with ‘including,’ ‘containing,’ or‘characterized by,’ and is inclusive or open-ended and does not excludeadditional, unrecited elements or method steps; the term ‘having’ shouldbe interpreted as ‘having at least;’ the term ‘includes’ should beinterpreted as ‘includes but is not limited to;’ the term ‘example’ isused to provide exemplary instances of the item in discussion, not anexhaustive or limiting list thereof; adjectives such as ‘known’,‘normal’, ‘standard’, and terms of similar meaning should not beconstrued as limiting the item described to a given time period or to anitem available as of a given time, but instead should be read toencompass known, normal, or standard technologies that may be availableor known now or at any time in the future; and use of terms like‘preferably,’ ‘preferred,’ ‘desired,’ or ‘desirable,’ and words ofsimilar meaning should not be understood as implying that certainfeatures are critical, essential, or even important to the structure orfunction of the invention, but instead as merely intended to highlightalternative or additional features that may or may not be utilized in aparticular embodiment of the invention. Likewise, a group of itemslinked with the conjunction ‘and’ should not be read as requiring thateach and every one of those items be present in the grouping, but rathershould be read as ‘and/or’ unless expressly stated otherwise. Similarly,a group of items linked with the conjunction ‘or’ should not be read asrequiring mutual exclusivity among that group, but rather should be readas ‘and/or’ unless expressly stated otherwise.

Where a range of values is provided, it is understood that the upper andlower limit, and each intervening value between the upper and lowerlimit of the range is encompassed within the embodiments.

With respect to the use of substantially any plural and/or singularterms herein, those having skill in the art can translate from theplural to the singular and/or from the singular to the plural as isappropriate to the context and/or application. The varioussingular/plural permutations may be expressly set forth herein for sakeof clarity. The indefinite article ‘a’ or ‘an’ does not exclude aplurality. A single processor or other unit may fulfill the functions ofseveral items recited in the claims. The mere fact that certain measuresare recited in mutually different dependent claims does not indicatethat a combination of these measures cannot be used to advantage. Anyreference signs in the claims should not be construed as limiting thescope.

It will be further understood by those within the art that if a specificnumber of an introduced claim recitation is intended, such an intentwill be explicitly recited in the claim, and in the absence of suchrecitation no such intent is present. For example, as an aid tounderstanding, the following appended claims may contain usage of theintroductory phrases ‘at least one’ and ‘one or more’ to introduce claimrecitations. However, the use of such phrases should not be construed toimply that the introduction of a claim recitation by the indefinitearticles ‘a’ or ‘an’ limits any particular claim containing suchintroduced claim recitation to embodiments containing only one suchrecitation, even when the same claim includes the introductory phrases‘one or more’ or ‘at least one’ and indefinite articles such as ‘a’ or‘an’ (e.g., ‘a’ and/or ‘an’ should typically be interpreted to mean ‘atleast one’ or ‘one or more’); the same holds true for the use ofdefinite articles used to introduce claim recitations. In addition, evenif a specific number of an introduced claim recitation is explicitlyrecited, those skilled in the art will recognize that such recitationshould typically be interpreted to mean at least the recited number(e.g., the bare recitation of ‘two recitations,’ without othermodifiers, typically means at least two recitations, or two or morerecitations). Furthermore, in those instances where a conventionanalogous to ‘at least one of A, B, and C, etc.’ is used, in generalsuch a construction is intended in the sense one having skill in the artwould understand the convention (e.g., ‘a system having at least one ofA, B, and C’ would include but not be limited to systems that have Aalone, B alone, C alone, A and B together, A and C together, B and Ctogether, and/or A, B, and C together, etc.). In those instances where aconvention analogous to ‘at least one of A, B, or C, etc.’ is used, ingeneral such a construction is intended in the sense one having skill inthe art would understand the convention (e.g., ‘a system having at leastone of A, B, or C’ would include but not be limited to systems that haveA alone, B alone, C alone, A and B together, A and C together, B and Ctogether, and/or A, B, and C together, etc.). It will be furtherunderstood by those within the art that virtually any disjunctive wordand/or phrase presenting two or more alternative terms, whether in thedescription, claims, or drawings, should be understood to contemplatethe possibilities of including one of the terms, either of the terms, orboth terms. For example, the phrase ‘A or B’ will be understood toinclude the possibilities of ‘A’ or ‘B’ or ‘A and B.’

All numbers expressing quantities of ingredients, reaction conditions,and so forth used in the specification are to be understood as beingmodified in all instances by the term ‘about.’ Accordingly, unlessindicated to the contrary, the numerical parameters set forth herein areapproximations that may vary depending upon the desired propertiessought to be obtained. At the very least, and not as an attempt to limitthe application of the doctrine of equivalents to the scope of anyclaims in any application claiming priority to the present application,each numerical parameter should be construed in light of the number ofsignificant digits and ordinary rounding approaches.

Furthermore, although the foregoing has been described in some detail byway of illustrations and examples for purposes of clarity andunderstanding, it is apparent to those skilled in the art that certainchanges and modifications may be practiced. Therefore, the descriptionand examples should not be construed as limiting the scope of theinvention to the specific embodiments and examples described herein, butrather to also cover all modification and alternatives coming with thetrue scope and spirit of the invention.

What is claimed is:
 1. A method for processing sensor data from acontinuous analyte monitoring system, comprising: initializing a sensorof a continuous analyte monitoring system implanted within a body of ahost user, the sensor in electrical communication with a sensorelectronics of the continuous analyte monitoring system configured toreceive and process sensor data by the sensor; acquiring sensor data,using the sensor, to measure an analyte level in the host's body over afirst interval based on a first elapsed time since the sensor wasimplanted; determining whether the sensor has been previously used in aprevious sensor session or the sensor is a new sensor, whereindetermining whether the sensor has been previously used comprisesmeasuring a change in impedance of the sensor over a predetermined timeperiod after implantation, and identifying that the measured change inimpedance is substantially insignificant or levels off over at least aportion of the predetermined time period; upon determining the sensor isa new sensor, adjusting the acquired sensor data to compensate forsensor drift of the new sensor by applying a first set of time-dependentalgorithmic functions to the sensor data associated with the firstinterval, wherein the first set of time-dependent algorithmic functionscomprise a first boundary of acceptability including a first drift rateof sensitivity over time and/or a first drift of baseline over time;acquiring further sensor data, using the sensor, to measure the analytelevel over a second interval based on a second elapsed time since thesensor was implanted and after the first interval; and adjusting theacquired further sensor data by applying a second set of time-dependentalgorithmic functions to the sensor data associated with the secondinterval, wherein the second set of time-dependent algorithmic functionscomprise a second boundary of acceptability including a second driftrate of sensitivity over time and/or a second drift of baseline overtime, wherein the first and second set of time-dependent algorithmicfunctions comprise first and second drift compensation functions, andwherein the first and second drift compensation functions differ in theamount of drift compensation that they apply.
 2. The method of claim 1,wherein the first boundary delineates acceptable slopes and baselines ofa conversion function and the second boundary delineates acceptableslopes and baselines of the conversion function.
 3. The method of claim1, wherein the first and second set of time-dependent algorithmicfunctions comprise first and second parameters associated with aconversion function.
 4. The method of claim 1, wherein the applying thesecond set of time-dependent algorithmic functions to the sensor dataassociated with the second interval comprises dynamically applying apriori information based on time since sensor implantation.
 5. Themethod of claim 1, wherein the applying the second set of time-dependentalgorithmic functions to the sensor data associated with the secondinterval comprises dynamically adapting a parameter of the second set oftime-dependent algorithmic functions based on a prior knowledge oftime-based sensor behavior during implantation.